diff --git a/IzzyLib/misc.py b/IzzyLib/misc.py index b96e8cb..3821812 100644 --- a/IzzyLib/misc.py +++ b/IzzyLib/misc.py @@ -20,7 +20,7 @@ def boolean(v, fail=True): '''convert string to True''' return True - elif value in [0, False, None, 'off', 'n', 'no', 'false', 'disable', '']: + elif value in [0, False, None, 'off', 'n', 'no', 'false', 'disable', 'none', '']: '''convert string to False''' return False diff --git a/IzzyLib/template.py b/IzzyLib/template.py index 747fac9..1755eb9 100644 --- a/IzzyLib/template.py +++ b/IzzyLib/template.py @@ -122,7 +122,7 @@ def setup(fwork='sanic'): ) -def renderTemplate(tplfile, context, request=None, headers=dict(), cookies=dict(), **kwargs): +def renderTemplate(tplfile, context={}, request=None, headers=dict(), cookies=dict(), **kwargs): if not isinstance(context, dict): raise TypeError(f'context for {tplfile} not a dict')