Merge branch 'ticket/master/170-mail-handler-dispatch'

pull/351/head
Eric Davis 14 years ago
commit 31df55421b
  1. 10
      app/models/mail_handler.rb

@ -100,7 +100,7 @@ class MailHandler < ActionMailer::Base
elsif m = email.subject.match(MESSAGE_REPLY_SUBJECT_RE) elsif m = email.subject.match(MESSAGE_REPLY_SUBJECT_RE)
receive_message_reply(m[1].to_i) receive_message_reply(m[1].to_i)
else else
receive_issue dispatch_to_default
end end
rescue ActiveRecord::RecordInvalid => e rescue ActiveRecord::RecordInvalid => e
# TODO: send a email to the user # TODO: send a email to the user
@ -114,6 +114,14 @@ class MailHandler < ActionMailer::Base
false false
end end
# Dispatch the mail to the default method handler, receive_issue
#
# This can be overridden or patched to support handling other incoming
# email types
def dispatch_to_default
receive_issue
end
# Creates a new issue # Creates a new issue
def receive_issue def receive_issue
project = target_project project = target_project

Loading…
Cancel
Save