lib/html2rss/attribute_post_processors/gsub.rb in html2rss-0.12.0 vs lib/html2rss/attribute_post_processors/gsub.rb in html2rss-0.13.0
- old
+ new
@@ -25,12 +25,12 @@
# `replacement` can be a String or a Hash.
#
# See the doc on [String#gsub](https://ruby-doc.org/core/String.html#method-i-gsub) for more info.
class Gsub < Base
def self.validate_args!(value, context)
- assert_type value, String, :value
+ assert_type value, String, :value, context:
expect_options(%i[replacement pattern], context)
- assert_type context.dig(:options, :replacement), [String, Hash], :replacement
+ assert_type context.dig(:options, :replacement), [String, Hash], :replacement, context:
end
##
# @param value [String]
# @param context [Item::Context]