diff options
author | Marcin Kuzminski <marcin@python-works.com> | 2013-01-24 01:20:03 +0100 |
---|---|---|
committer | Marcin Kuzminski <marcin@python-works.com> | 2013-01-24 01:20:03 +0100 |
commit | 3000f2b6783cb1257b3b4f03359b0fa6e392a1bb (patch) | |
tree | fb9f577e7da5fa9690e2ea33f978e91d3e2f9a24 | |
parent | ba1093d80d0c8c13b1144d955cb898a479c2bd22 (diff) |
safe_int should also catch TypeError
--HG--
extra : source : c0b0351233ec593c040638970acb13b6adb5eaf5
-rw-r--r-- | rhodecode/lib/utils2.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rhodecode/lib/utils2.py b/rhodecode/lib/utils2.py index 890effce..a0bc7d85 100644 --- a/rhodecode/lib/utils2.py +++ b/rhodecode/lib/utils2.py @@ -182,7 +182,7 @@ def safe_int(val, default=None): try: val = int(val) - except ValueError: + except (ValueError, TypeError): val = default return val |