Fix lavalink connection init
This commit is contained in:
parent
c5b50cf73b
commit
b9f1ccc39e
2 changed files with 4 additions and 5 deletions
5
app.js
5
app.js
|
@ -35,7 +35,7 @@ import { paths } from "./utils/collections.js";
|
||||||
// database stuff
|
// database stuff
|
||||||
import database from "./utils/database.js";
|
import database from "./utils/database.js";
|
||||||
// lavalink stuff
|
// lavalink stuff
|
||||||
import { checkStatus, reload } from "./utils/soundplayer.js";
|
import { checkStatus, reload, connect, status, connected } from "./utils/soundplayer.js";
|
||||||
// events
|
// events
|
||||||
import { endBroadcast, startBroadcast } from "./utils/misc.js";
|
import { endBroadcast, startBroadcast } from "./utils/misc.js";
|
||||||
import { parseThreshold } from "./utils/tempimages.js";
|
import { parseThreshold } from "./utils/tempimages.js";
|
||||||
|
@ -210,6 +210,9 @@ esmBot ${esmBotVersion} (${process.env.GIT_REV})
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// connect to lavalink
|
||||||
|
if (!status && !connected) connect(client);
|
||||||
|
|
||||||
client.connect();
|
client.connect();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
import { activityChanger, checkBroadcast } from "../utils/misc.js";
|
import { activityChanger, checkBroadcast } from "../utils/misc.js";
|
||||||
import { connect, status, connected } from "../utils/soundplayer.js";
|
|
||||||
import { send } from "../utils/handler.js";
|
import { send } from "../utils/handler.js";
|
||||||
import { generateList, createPage } from "../utils/help.js";
|
import { generateList, createPage } from "../utils/help.js";
|
||||||
import { logger } from "../utils/logger.js";
|
import { logger } from "../utils/logger.js";
|
||||||
|
@ -28,9 +27,6 @@ export default async (client) => {
|
||||||
logger.log("info", "The help docs have been generated.");
|
logger.log("info", "The help docs have been generated.");
|
||||||
}
|
}
|
||||||
|
|
||||||
// connect to lavalink
|
|
||||||
if (!status && !connected) connect(client);
|
|
||||||
|
|
||||||
checkBroadcast(client);
|
checkBroadcast(client);
|
||||||
activityChanger(client);
|
activityChanger(client);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue