fixing auth issues
This commit is contained in:
parent
e38006bbc4
commit
a1401529e3
@ -8,18 +8,19 @@ module.exports = {
|
||||
private: true,
|
||||
run: async (client, interaction) => {
|
||||
const file = './cache/' + interaction.user.id
|
||||
|
||||
console.log(process.env.USER)
|
||||
console.log(process.env.PASS)
|
||||
|
||||
unirest
|
||||
.post(`https://${process.env.PUBLIC_URL}/api/chat`)
|
||||
.headers({ 'Accept': 'application/json', 'Content-Type': 'application/json' })
|
||||
.auth({
|
||||
user: process.env.USER,
|
||||
user: process.env.USERNAME,
|
||||
pass: process.env.PASS,
|
||||
sendImmediately: true
|
||||
})
|
||||
.then((response) => {
|
||||
console.log(response)
|
||||
// console.log(response)
|
||||
const obj = { id: response.body }
|
||||
|
||||
jsonfile.writeFile(file, obj, function (err) {
|
||||
|
Loading…
Reference in New Issue
Block a user