Exemplo n.º 1
0
 def __init__(self, connection, username, users_list, users_count):
     Thread.__init__(self)
     self.connection = connection
     self.users_list = users_list
     self.users_count = users_count
     user.register(conn, username)
     self.user_id = user.sign_in(conn, username)
Exemplo n.º 2
0
def sign_in(user_name):
    if user.sign_in(user_name):
        print("Signed in successfully. Enjoy your day.")
    else:
        print("Already signed in. Signout first.")
Exemplo n.º 3
0
def sign_in(str, sid):
    res = user.sign_in(str)
    sio.emit('signed-in', res, room=sid['_value'])
    if res is not None:
        sids[res['id']] = sid['_value']