docs: move event docstrings to the emitting line of code

This commit is contained in:
SpaceEEC
2018-11-27 21:28:36 +01:00
parent 1d1b3f25e1
commit fd21bbb7bf
21 changed files with 109 additions and 103 deletions

View File

@@ -8,6 +8,12 @@ class GuildUpdateAction extends Action {
const guild = client.guilds.get(data.id);
if (guild) {
const old = guild._update(data);
/**
* Emitted whenever a guild is updated - e.g. name change.
* @event Client#guildUpdate
* @param {Guild} oldGuild The guild before the update
* @param {Guild} newGuild The guild after the update
*/
client.emit(Events.GUILD_UPDATE, old, guild);
return {
old,
@@ -22,11 +28,5 @@ class GuildUpdateAction extends Action {
}
}
/**
* Emitted whenever a guild is updated - e.g. name change.
* @event Client#guildUpdate
* @param {Guild} oldGuild The guild before the update
* @param {Guild} newGuild The guild after the update
*/
module.exports = GuildUpdateAction;