| 124 | self.drop() |
| 125 | |
| 126 | def _extractHelloArguments(self, hello): |
| 127 | username = hello["username"] if "username" in hello else None |
| 128 | roomName = hello["room"]["name"] if "room" in hello else None |
| 129 | version = hello["version"] if "version" in hello else None |
| 130 | version = hello["realversion"] if "realversion" in hello else version # Used for 1.2.X compatibility |
| 131 | motd = hello["motd"] if "motd" in hello else None |
| 132 | features = hello["features"] if "features" in hello else None |
| 133 | return username, roomName, version, motd, features |
| 134 | |
| 135 | def handleHello(self, hello): |
| 136 | username, roomName, version, motd, featureList = self._extractHelloArguments(hello) |