]> jfr.im git - irc/rizon/acid.git/commitdiff
Fix trying to parse unicode as ascii. (I guess we just ignore it?)
authorOrillion <redacted>
Thu, 8 Oct 2015 21:59:50 +0000 (23:59 +0200)
committerOrillion <redacted>
Thu, 8 Oct 2015 21:59:50 +0000 (23:59 +0200)
pyva/pyva/src/main/python/trivia/trivia_engine.py

index 3ebc7592604ac028e4a610f4283dda64e1ebbc69..36e5c67ef1ea8e7840abc486e3344ec1603aa75a 100644 (file)
@@ -168,11 +168,12 @@ class Trivia(object):
                                        found = True
                                        break
                        except ValueError:
-                               if a.lower() in answer.lower():
-                                       found = True
-                                       break
-                       except:
-                               pass # XXX unicode
+                               try:
+                                       if a.lower() in answer.lower():
+                                               found = True
+                                               break
+                               except:
+                                       pass # XXX unicode
 
                if not found:
                        return