lib/nanoc/base/compilation/rules_collection.rb in nanoc-3.6.7 vs lib/nanoc/base/compilation/rules_collection.rb in nanoc-3.6.8
- old
+ new
@@ -123,21 +123,21 @@
def routing_rules_for(rep)
rules = {}
@item_routing_rules.each do |rule|
next if !rule.applicable_to?(rep.item)
next if rule.rep_name != rep.name
- next if rules.has_key?(rule.snapshot_name)
+ next if rules.key?(rule.snapshot_name)
rules[rule.snapshot_name] = rule
end
rules
end
# Finds the filter name and arguments to use for the given layout.
#
# @param [Nanoc::Layout] layout The layout for which to fetch the filter.
#
- # @return [Array, nil] A tuple containing the filter name and the filter
+ # @return [Array, nil] A tuple containing the filter name and the filter
# arguments for the given layout.
def filter_for_layout(layout)
@layout_filter_mapping.each_pair do |layout_identifier, filter_name_and_args|
return filter_name_and_args if layout.identifier =~ layout_identifier
end