fix #16506 by changing the example (#16580)

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
This commit is contained in:
Miran 2021-01-04 21:46:36 +01:00 • committed by GitHub
commit d2f4f25b56
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -35,7 +35,7 @@
## server.listen Port(8080)
## while true:
## if server.shouldAcceptRequest():
## asyncCheck server.acceptRequest(cb)
## await server.acceptRequest(cb)
## else:
## poll()
##
@ -382,7 +382,7 @@ when not defined(testing) and isMainModule:
server.listen Port(5555)
while true:
if server.shouldAcceptRequest():
asyncCheck server.acceptRequest(cb)
await server.acceptRequest(cb)
else:
poll()