DB-Script
Discord Server
NPM
Search…
DB-Script
Getting Started
NPM Updates
Known Bugs
Functionalities
Bot Functions
Events
BanCommand
BotJoinCommand
BotLeaveCommand
ChannelCreateCommand
ChannelDeleteCommand
ChannelUpdateCommand
EmojiCreateCommand
EmojiDeleteCommand
GuildUpdateCommand
JoinedCommand
LeaveCommand
LoopCommand
MessageDeleteCommand
MessageEditEvent
RateLimitCommand
ReadyCommand
ReactionAddCommand
ReactionRemoveCommand
RoleCreateCommand
RoleDeleteCommand
UnbanCommand
UserUpdateCommand
Functions
Guides
Other
Contributors
Discord Server
FAQs
Staff
Powered By
GitBook
UnbanCommand
Triggers when a guild member is unbanned from the guild in any fashion. Great for ban logs!
​
1
bot.UnbanCommand({
2
name: "channelID or variable",
3
code: `
4
CODE GOES HERE!
5
`
6
})
7
bot.onUnban()
Copied!
Example:
1
bot.UnbanCommand({
2
name: "$getServerVar[channel]",
3
code: `
4
$tag has been unbanned from $guildName!
5
​
6
`
7
})
8
bot.onUnban()
Copied!
​
​
Example 1:
The event placed in the main file.
1
bot.UnbanCommand({
2
name: "$getServerVar[channel]",
3
code: `
4
$tag[$authorID] was unbanned from $guildName
5
`
6
})
7
bot.onUnban()
Copied!
​
Example 2: The event placed in the
event handler
(its own file)
bot.onUnban()
- Goes in the main file to be able to call the event!
1
module.exports.UnbanCommand = ({
2
name: "$getServerVar[channel]",
3
code: `
4
$tag[$authorID] was unbanned from $guildName
5
`
6
}
Copied!
Previous
RoleDeleteCommand
Next
UserUpdateCommand
Last modified
10mo ago
Copy link
Contents