Instead of return None, get_key now returns an empty string.
Also wrapped get_key calls in str
return scope
except (TypeError, KeyError):
pass
+ return ''
def get_partial(name):
try:
output += key
elif tag == 'variable':
- output += html_escape(get_key(key))
+ output += html_escape(str(get_key(key)))
elif tag == 'no escape':
- output += get_key(key)
+ output += str(get_key(key))
elif tag == 'section':
scope = get_key(key)