Improve code
This commit is contained in:
parent
5c526f1371
commit
313221a2cf
|
@ -3,8 +3,11 @@
|
||||||
import asyncio
|
import asyncio
|
||||||
from nio import AsyncClient
|
from nio import AsyncClient
|
||||||
|
|
||||||
async def main():
|
def main():
|
||||||
|
asyncio.get_event_loop().run_until_complete(loop())
|
||||||
|
|
||||||
|
async def loop():
|
||||||
print(123)
|
print(123)
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
asyncio.get_event_loop().run_until_complete(main())
|
main()
|
||||||
|
|
Reference in a new issue