Fix make_constant() in the AST module, to always return a

constant.  It was failing to do so for timestamps, instead
returning a STIXdatetime object.
pull/1/head
Michael Chisholm 2020-09-04 14:46:49 -04:00
parent 72a032c6e3
commit f2691e89f5
1 changed files with 1 additions and 1 deletions

View File

@ -227,7 +227,7 @@ def make_constant(value):
return value
try:
return parse_into_datetime(value)
return TimestampConstant(value)
except (ValueError, TypeError):
pass