diff --git a/webssh/handler.py b/webssh/handler.py index a536a82..8d1d5d2 100644 --- a/webssh/handler.py +++ b/webssh/handler.py @@ -234,7 +234,7 @@ class IndexHandler(MixinHandler, tornado.web.RequestHandler): def get_hostname(self): value = self.get_value('hostname') - if not (is_valid_hostname(value) | is_valid_ip_address(value)): + if not (is_valid_hostname(value) or is_valid_ip_address(value)): raise InvalidValueError('Invalid hostname: {}'.format(value)) return value