lib/openwfe/expressions/fe_misc.rb in openwferu-0.9.4 vs lib/openwfe/expressions/fe_misc.rb in openwferu-0.9.5
- old
+ new
@@ -86,14 +86,15 @@
escape = lookup_boolean_attribute('escape', workitem, false)
code = OpenWFE::lookup_vf_attribute(self, workitem, 'code')
code = OpenWFE::fetch_text_content(self, workitem, escape) \
- if not code
+ unless code
result = eval(code.to_s)
- OpenWFE::set_result(workitem, result) if result != nil
+ OpenWFE::set_result(workitem, result) \
+ if result != nil # 'false' is a valid result
reply_to_parent(workitem)
end
end