diff options
author | marzavec <admin@marzavec.com> | 2020-03-16 16:50:21 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-16 16:50:21 +0100 |
commit | be310af3bd7f38b2c17d5fbec6f75ac903fd4750 (patch) | |
tree | eece3fdefbe2cb023c90563f2f9ddd74fce8d867 /server/src/commands/mod | |
parent | Merge pull request #99 from MinusGix/joinToHash (diff) | |
parent | Make ban command broadcast information about user and banner (diff) | |
download | hackchat-be310af3bd7f38b2c17d5fbec6f75ac903fd4750.tar.gz hackchat-be310af3bd7f38b2c17d5fbec6f75ac903fd4750.zip |
Merge pull request #98 from MinusGix/BanMinor
More verbose ban event + UAC getUserDetails additions
Diffstat (limited to 'server/src/commands/mod')
-rw-r--r-- | server/src/commands/mod/ban.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/server/src/commands/mod/ban.js b/server/src/commands/mod/ban.js index b33b55e..994bc1c 100644 --- a/server/src/commands/mod/ban.js +++ b/server/src/commands/mod/ban.js @@ -46,12 +46,16 @@ export async function run(core, server, socket, data) { server.broadcast({ cmd: 'info', text: `Banned ${targetNick}`, + user: UAC.getUserDetails(badClient), }, { channel: socket.channel, level: (level) => level < UAC.levels.moderator }); // notify mods server.broadcast({ cmd: 'info', text: `${socket.nick}#${socket.trip} banned ${targetNick} in ${socket.channel}, userhash: ${badClient.hash}`, + channel: socket.channel, + user: UAC.getUserDetails(badClient), + banner: UAC.getUserDetails(socket), }, { level: UAC.isModerator }); // force connection closed |