off-loaded common functions

This commit is contained in:
DeSqBlocki
2025-02-08 17:07:13 +01:00
parent 5397e076ca
commit f978dbdf2e
7 changed files with 22 additions and 13 deletions
+3 -1
View File
@@ -1,6 +1,8 @@
const fs = require('node:fs')
const path = require('node:path');
const { dClient, mClient, tClient } = require('..');
const { refreshAccessToken } = require('../functions');
const tmi = require('tmi.js')
const folderPath = path.join(__dirname, '../events')
const eventFolders = fs.readdirSync(folderPath)
@@ -66,7 +68,7 @@ tClient.on('disconnected', async (reason) => {
username: tCreds.username,
password: `oauth:${tCreds.token.access_token}`,
},
channels: channels,
channels: tClient.channels,
});
await tClient.connect();