mirror of
https://github.com/veganhacktivists/arabot.git
synced 2025-05-19 10:44:13 +02:00
refactor(arabot): remove the need for container
This commit is contained in:
parent
4d819d87d2
commit
8c06bb6b88
@ -17,7 +17,7 @@
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { container, Listener } from '@sapphire/framework';
|
||||
import { Listener } from '@sapphire/framework';
|
||||
import type {
|
||||
VoiceState, CategoryChannel, VoiceChannel, TextChannel,
|
||||
} from 'discord.js';
|
||||
@ -48,9 +48,8 @@ class VerificationLeaveVCListener extends Listener {
|
||||
let verifier = false;
|
||||
|
||||
// Check for undefined variables
|
||||
const { client } = container;
|
||||
const { channel } = oldState;
|
||||
const guild = client.guilds.cache.get(newState.guild.id);
|
||||
const { guild } = newState;
|
||||
|
||||
if (channel === null || guild === undefined) {
|
||||
console.error('Verification channel not found');
|
||||
|
Loading…
x
Reference in New Issue
Block a user