put is_mobile and is_tablet in the result of user_agent()

This commit is contained in:
Leonel Câmara
2017-08-08 00:50:55 +01:00
parent 0b41ed36f9
commit 8533fa0d00
2 changed files with 10 additions and 2 deletions
+3
View File
@@ -678,6 +678,9 @@ def simple_detect(agent):
class mobilize(object):
"""
Decorator for controller functions so they use different views for mobile devices.
WARNING: If you update httpagentparser make sure to leave mobilize for
backwards compatibility.
"""
def __init__(self, func):
self.func = func