userLeft method
Implementation
void userLeft(UserLeftData data) {
final connection = getConnection(data.userId!);
if (connection != null) {
this.emit('user-left', null, connection);
connection.close();
connections!
.removeWhere((element) => element!.userId! == connection.userId);
}
}