module Roda::RodaPlugins::Mailer::ClassMethods
def mail(path, *args)
and arguments. You can further manipulate the returned mail object before
Return a Mail::Message instance for the email for the given request path
def mail(path, *args) mail = ::Mail.new unless mail.equal?(allocate.call(PATH_INFO=>path, SCRIPT_NAME=>EMPTY_STRING, REQUEST_METHOD=>MAIL, RACK_INPUT=>StringIO.new, RODA_MAIL=>mail, RODA_MAIL_ARGS=>args, &route_block)) raise Error, "route did not return mail instance for #{path.inspect}, #{args.inspect}" end mail end
def sendmail(*args)
def sendmail(*args) mail(*args).deliver end