fix domain env
This commit is contained in:
parent
1be59e5543
commit
c1640af4c1
@ -18,7 +18,7 @@ exports.run = (client, message, args, level) => { // eslint-disable-line no-unus
|
|||||||
|
|
||||||
|
|
||||||
// Setting up our Request, using getUserByName method
|
// Setting up our Request, using getUserByName method
|
||||||
var Request = http.get('https://board.grwh.work/jsonrpc.php').headers({ Accept: 'application/json', 'Content-Type': 'application/json' }).send({ "jsonrpc": "2.0", "method": "getUserByName", "id": 0, "params": { "username": username[0] } });
|
var Request = http.get('https://' + process.env.ROOT_DOMAIN + '/jsonrpc.php').headers({ Accept: 'application/json', 'Content-Type': 'application/json' }).send({ "jsonrpc": "2.0", "method": "getUserByName", "id": 0, "params": { "username": username[0] } });
|
||||||
|
|
||||||
// Begin the request and send authenication using the jsonrpc2.0 protocol.
|
// Begin the request and send authenication using the jsonrpc2.0 protocol.
|
||||||
Request.auth({
|
Request.auth({
|
||||||
|
@ -13,7 +13,7 @@ exports.run = async (client, interaction) => {
|
|||||||
await interaction.deferReply();
|
await interaction.deferReply();
|
||||||
// const reply = await interaction.editReply("Ping?");
|
// const reply = await interaction.editReply("Ping?");
|
||||||
// await interaction.editReply(`Pong! Latency is ${reply.createdTimestamp - interaction.createdTimestamp}ms. API Latency is ${Math.round(client.ws.ping)}ms.`);
|
// await interaction.editReply(`Pong! Latency is ${reply.createdTimestamp - interaction.createdTimestamp}ms. API Latency is ${Math.round(client.ws.ping)}ms.`);
|
||||||
var Request = http.post('https://board.grwh.work/jsonrpc.php').headers({ Accept: 'application/json', 'Content-Type': 'application/json' }).send({ "jsonrpc": "2.0", "method": "getAllProjects", "id": 0 });
|
var Request = http.post('https://' + process.env.ROOT_DOMAIN + '/jsonrpc.php').headers({ Accept: 'application/json', 'Content-Type': 'application/json' }).send({ "jsonrpc": "2.0", "method": "getAllProjects", "id": 0 });
|
||||||
|
|
||||||
Request.auth({
|
Request.auth({
|
||||||
user: 'jsonrpc',
|
user: 'jsonrpc',
|
||||||
|
@ -62,7 +62,7 @@ exports.run = async (client, interaction) => {
|
|||||||
await interaction.update({ content: '', components: [] });
|
await interaction.update({ content: '', components: [] });
|
||||||
console.log(interaction.values[0]);
|
console.log(interaction.values[0]);
|
||||||
|
|
||||||
var Request = http.get('https://board.grwh.work/jsonrpc.php').headers({ Accept: 'application/json', 'Content-Type': 'application/json' }).send({ "jsonrpc": "2.0", "method": "getBoard", "id": 0, "params": [interaction.values[0]] });
|
var Request = http.get('https://' + process.env.ROOT_DOMAIN + '/jsonrpc.php').headers({ Accept: 'application/json', 'Content-Type': 'application/json' }).send({ "jsonrpc": "2.0", "method": "getBoard", "id": 0, "params": [interaction.values[0]] });
|
||||||
|
|
||||||
// Begin the request and send authenication using the jsonrpc2.0 protocol.
|
// Begin the request and send authenication using the jsonrpc2.0 protocol.
|
||||||
Request.auth({
|
Request.auth({
|
||||||
|
@ -34,7 +34,7 @@ exports.run = async (client, interaction) => {
|
|||||||
await interaction.deferReply();
|
await interaction.deferReply();
|
||||||
|
|
||||||
// Setting up our Request, using getAllProjects method
|
// Setting up our Request, using getAllProjects method
|
||||||
var Request = http.get('https://board.grwh.work/jsonrpc.php').headers({ Accept: 'application/json', 'Content-Type': 'application/json' }).send({ "jsonrpc": "2.0", "method": "getAllProjects", "id": 0 });
|
var Request = http.get('https://' + process.env.ROOT_DOMAIN + '/jsonrpc.php').headers({ Accept: 'application/json', 'Content-Type': 'application/json' }).send({ "jsonrpc": "2.0", "method": "getAllProjects", "id": 0 });
|
||||||
|
|
||||||
// Begin the request and send authenication using the jsonrpc2.0 protocol.
|
// Begin the request and send authenication using the jsonrpc2.0 protocol.
|
||||||
Request.auth({
|
Request.auth({
|
||||||
|
Loading…
Reference in New Issue
Block a user