mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-23 17:06:16 -04:00
clientReady hook- pass entire message, updated doc
This commit is contained in:
parent
a31e6cd332
commit
21f0d12d31
2 changed files with 19 additions and 0 deletions
|
@ -384,3 +384,20 @@ exports.userLeave = function(hook, session, callback) {
|
|||
console.log('%s left pad %s', session.author, session.padId);
|
||||
};
|
||||
```
|
||||
|
||||
### clientReady
|
||||
Called from src/node/handler/PadMessageHandler.js
|
||||
|
||||
This in context:
|
||||
|
||||
1. message
|
||||
|
||||
This hook gets called when handling a CLIENT_READY which is the first message from the client to the server.
|
||||
|
||||
Example:
|
||||
|
||||
```
|
||||
exports.clientReady = function(hook, message) {
|
||||
console.log('Client has entered the pad' + message.padId);
|
||||
};
|
||||
```
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue