From 96535204dd09a132dd0bcf011df3719b58f49585 Mon Sep 17 00:00:00 2001
From: Eric Olson
Date: Sat, 17 Dec 2016 21:34:58 -0600
Subject: [PATCH] putChild seems to require bytes type
---
_posts/2015-09-11-playing-with-websockets.markdown | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/_posts/2015-09-11-playing-with-websockets.markdown b/_posts/2015-09-11-playing-with-websockets.markdown
index 13e3e0d..55453ab 100644
--- a/_posts/2015-09-11-playing-with-websockets.markdown
+++ b/_posts/2015-09-11-playing-with-websockets.markdown
@@ -97,7 +97,7 @@ if __name__ == "__main__":
factory.protocol = SomeServerProtocol
resource = WebSocketResource(factory)
# websockets resource on "/ws" path
- root.putChild(u"ws", resource)
+ root.putChild(b"ws", resource)
site = Site(root)
reactor.listenTCP(8080, site)