generated from mononoki/pyproj
[+!] all but small
some small modifications, tests added
This commit is contained in:
@@ -61,7 +61,7 @@ class Session:
|
||||
|
||||
|
||||
self.static_meta["com"] = set(data.get("com", []))
|
||||
self.static_meta["auth"] = set(data.get("token", []))
|
||||
self.static_meta["auth"] = data.get("token")
|
||||
|
||||
self.state = "token"
|
||||
|
||||
@@ -134,8 +134,8 @@ class Session:
|
||||
def send(self, package):
|
||||
#TODO
|
||||
#decide if we want dialect pack here or not
|
||||
if self.state != "stop":
|
||||
asyncio.create_task( self.connection.send(package) )
|
||||
if self.state in {"stop", "migrated"} : return
|
||||
asyncio.create_task( self.connection.send(package) )
|
||||
|
||||
async def stop(self):
|
||||
self.state = "stop"
|
||||
|
||||
Reference in New Issue
Block a user