lib/grumlin/shortcuts/storage.rb in grumlin-1.0.3.beta1 vs lib/grumlin/shortcuts/storage.rb in grumlin-1.0.3
- old
+ new
@@ -33,22 +33,26 @@
@storage[name] = shortcut
sc = step_class
shortcut_methods_module.define_method(name) do |*args, **params|
- next sc.new(name, args: args, params: params, previous_step: self, pool: Grumlin.default_pool)
+ next sc.new(name, args: args, params: params, previous_step: self, pool: pool)
end
extend_traversal_classes(shortcut) unless shortcut.lazy?
end
def add_from(other)
other.storage.each do |name, shortcut|
add(name, shortcut)
end
end
+ def g(middlewares: Grumlin.default_middlewares)
+ traversal_start_class.new(pool: Grumlin.default_pool, middlewares: middlewares)
+ end
+
def __
- traversal_start_class.new(pool: Grumlin.default_pool)
+ traversal_start_class.new
end
def traversal_start_class
@traversal_start_class ||= shortcut_aware_class(Grumlin::TraversalStart)
end