Don't hook the timer hook before we're connected.
This commit is contained in:
parent
a4d4e56919
commit
594706e0af
2 changed files with 18 additions and 8 deletions
9
main.py
9
main.py
|
|
@ -225,6 +225,15 @@ def connect_cb(data, status, gnutls_rc, sock, error, ip_address):
|
|||
server.name
|
||||
)
|
||||
|
||||
if not server.timer_hook:
|
||||
server.timer_hook = W.hook_timer(
|
||||
1 * 1000,
|
||||
0,
|
||||
0,
|
||||
"matrix_timer_cb",
|
||||
server.name
|
||||
)
|
||||
|
||||
server.fd_hook = hook
|
||||
server.connected = True
|
||||
server.connecting = False
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue