mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-22 08:26:16 -04:00
Added a userLeave
hook that gets called when a user leaves a pad
This commit is contained in:
parent
49bba7dfe2
commit
2f8b860e69
2 changed files with 20 additions and 0 deletions
|
@ -145,6 +145,9 @@ exports.handleDisconnect = function(client)
|
|||
|
||||
//Go trough all user that are still on the pad, and send them the USER_LEAVE message
|
||||
client.broadcast.to(session.padId).json.send(messageToTheOtherUsers);
|
||||
|
||||
// Allow plugins to hook into users leaving the pad
|
||||
hooks.callAll("userLeave", session);
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue