lib/roda/plugins/mail_processor.rb in roda-3.58.0 vs lib/roda/plugins/mail_processor.rb in roda-3.59.0
- old
+ new
@@ -463,22 +463,21 @@
end
def #{field}(address, &block)
on(:#{field}=>address, &block)
end
+ END
+ next if [:rcpt, :text, :body, :subject].include?(field)
+
+ class_eval(<<-END, __FILE__, __LINE__+1)
private
def match_#{field}(address)
_match_address(:#{field}, address, Array(mail.#{field}))
end
END
end
-
- undef_method :match_rcpt
- undef_method :match_text
- undef_method :match_body
- undef_method :match_subject
# Same as +header+, but also mark the message as being handled.
def handle_header(key, value=nil)
header(key, value) do |*args|
handle do