lib/ruote/parser.rb in ruote-2.1.10 vs lib/ruote/parser.rb in ruote-2.1.11
- old
+ new
@@ -53,11 +53,11 @@
(return XmlParser.parse(definition)) rescue nil
(return Rufus::Json.decode(definition)) rescue nil
(return ruby_eval(definition)) rescue nil
- if definition.index("\n") == nil
+ if definition.index("\n").nil? && definition.index(' ').nil?
raise ArgumentError.new(
"remote process definitions are not allowed"
) if Ruote::Parser.remote?(definition) && @context['remote_definition_allowed'] != true
@@ -75,10 +75,10 @@
def self.parse (d)
unless @parser
require 'ostruct'
- require 'ruote/util/treechecker'
+ require 'ruote/svc/treechecker'
@parser = Ruote::Parser.new(
OpenStruct.new('treechecker' => Ruote::TreeChecker.new({})))
end