lib/dagger/generator/require_name.rb in ruby-dagger-0.1.1 vs lib/dagger/generator/require_name.rb in ruby-dagger-0.2.0

- old
+ new

@@ -1,5 +1,7 @@ +# frozen_string_literal: true + require_relative '../generator' module Dagger module Generate # Set requirement for further processing. @@ -7,12 +9,11 @@ # _default.key: # - require_name: regexp # - ... class RequireName < Dagger::Generator def process(regexps) - string = dictionary['_meta.name'] stop unless enumerable(regexps).any? do |regexp| - ::Regexp.new(regexp).match?(string) + ::Regexp.new(regexp).match?(vertex.name) end end end end end