Skip to content

Conversation

@MaelkMark
Copy link
Contributor

Call the self.client_left() disconnect callback after removing the client from the self.clients list.

When a client disconnects, it first removes the client from the self.clients list, and only then calls the self.client_left() callback to make sure the program doesn't get false data. Just like when a new client connects: first it adds the client to the self.clients list and only then calls the self.new_client callback.

This change makes the connection/disconnection callbacks more reliable and consistent.

Call the self.client_left() disconnect callback after removing the client from the self.clients list.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant