mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-11 09:03:29 +01:00
refactor: make use of destructuring for Constants (#1942)
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
const Action = require('./Action');
|
||||
const Constants = require('../../util/Constants');
|
||||
const { Events } = require('../../util/Constants');
|
||||
|
||||
class GuildUpdateAction extends Action {
|
||||
handle(data) {
|
||||
@@ -8,7 +8,7 @@ class GuildUpdateAction extends Action {
|
||||
const guild = client.guilds.get(data.id);
|
||||
if (guild) {
|
||||
const old = guild._update(data);
|
||||
client.emit(Constants.Events.GUILD_UPDATE, old, guild);
|
||||
client.emit(Events.GUILD_UPDATE, old, guild);
|
||||
return {
|
||||
old,
|
||||
updated: guild,
|
||||
|
||||
Reference in New Issue
Block a user