1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-09 00:22:08 +03:00

readme: how to correctly auth to server, what error looks like if done wrong

This commit is contained in:
David Trejo
2012-03-05 17:31:47 -05:00
parent 234ae6be9a
commit cd5db44f66

View File

@@ -213,6 +213,9 @@ first command after connecting. This can be tricky to coordinate with reconnect
etc. To make this easier, `client.auth()` stashes `password` and will send it after each connection,
including reconnections. `callback` is invoked only once, after the response to the very first
`AUTH` command sent.
NOTE: Your call to `client.auth()` should not be inside the ready handler. If
you are doing this wrong, `client` will emit an error that looks
something like this `Error: Ready check failed: ERR operation not permitted`.
## client.end()