From 198fbf9f595161967082f062d47e280dd6b15061 Mon Sep 17 00:00:00 2001 From: mdipierro Date: Sun, 15 Mar 2015 14:32:29 -0500 Subject: [PATCH] allow URL('') --- gluon/html.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gluon/html.py b/gluon/html.py index 5f5f2a4e..d9c47887 100644 --- a/gluon/html.py +++ b/gluon/html.py @@ -274,7 +274,7 @@ def URL( if not isinstance(args, (list, tuple)): args = [args] - if not r: + if r is None: if a and not c and not f: (f, a, c) = (a, c, f) elif a and c and not f: @@ -283,18 +283,18 @@ def URL( if hasattr(current, 'request'): r = current.request - if r: + if r is not None: application = r.application controller = r.controller function = r.function env = r.env if extension is None and r.extension != 'html': extension = r.extension - if a: + if a is not None: application = a - if c: + if c is not None: controller = c - if f: + if f is not None: if not isinstance(f, str): if hasattr(f, '__name__'): function = f.__name__