misc: check templates are strings (#48504)
This commit is contained in:
parent
b3378e553e
commit
08eb5dbdf1
|
@ -520,7 +520,7 @@ class Template(object):
|
|||
|
||||
@classmethod
|
||||
def is_template_string(cls, string):
|
||||
return string and ('{{' in string or '{%' in string or '[' in string)
|
||||
return isinstance(string, str) and ('{{' in string or '{%' in string or '[' in string)
|
||||
|
||||
|
||||
# monkey patch django template Variable resolution to convert legacy
|
||||
|
|
Loading…
Reference in New Issue