diff options
author | Lin Jen-Shin <godfat@godfat.org> | 2016-05-19 01:19:25 +0300 |
---|---|---|
committer | Lin Jen-Shin <godfat@godfat.org> | 2016-05-19 01:25:45 +0300 |
commit | c337e748d385fea5c768a8e7de55975dca7fa484 (patch) | |
tree | f9646fbb68614b633964bc43d725296b61047fec /app/workers/email_receiver_worker.rb | |
parent | 3f4a6412dcc35c182d993cd1350459e8a4a1b8d1 (diff) |
so we use separate classes to handle different tasks
Diffstat (limited to 'app/workers/email_receiver_worker.rb')
-rw-r--r-- | app/workers/email_receiver_worker.rb | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/app/workers/email_receiver_worker.rb b/app/workers/email_receiver_worker.rb index 544b23da85e..af9006d8dde 100644 --- a/app/workers/email_receiver_worker.rb +++ b/app/workers/email_receiver_worker.rb @@ -24,25 +24,25 @@ class EmailReceiverWorker reason = nil case e - when Gitlab::Email::Receiver::SentNotificationNotFoundError + when Gitlab::Email::SentNotificationNotFoundError reason = "We couldn't figure out what the email is in reply to. Please create your comment through the web interface." - when Gitlab::Email::Receiver::ProjectNotFound + when Gitlab::Email::ProjectNotFound reason = "We couldn't find the project. Please check if there's any typo." - when Gitlab::Email::Receiver::EmptyEmailError + when Gitlab::Email::EmptyEmailError can_retry = true reason = "It appears that the email is blank. Make sure your reply is at the top of the email, we can't process inline replies." - when Gitlab::Email::Receiver::AutoGeneratedEmailError + when Gitlab::Email::AutoGeneratedEmailError reason = "The email was marked as 'auto generated', which we can't accept. Please create your comment through the web interface." - when Gitlab::Email::Receiver::UserNotFoundError + when Gitlab::Email::UserNotFoundError reason = "We couldn't figure out what user corresponds to the email. Please create your comment through the web interface." - when Gitlab::Email::Receiver::UserBlockedError + when Gitlab::Email::UserBlockedError reason = "Your account has been blocked. If you believe this is in error, contact a staff member." - when Gitlab::Email::Receiver::UserNotAuthorizedError + when Gitlab::Email::UserNotAuthorizedError reason = "You are not allowed to perform this action. If you believe this is in error, contact a staff member." - when Gitlab::Email::Receiver::NoteableNotFoundError + when Gitlab::Email::NoteableNotFoundError reason = "The thread you are replying to no longer exists, perhaps it was deleted? If you believe this is in error, contact a staff member." - when Gitlab::Email::Receiver::InvalidNoteError, - Gitlab::Email::Receiver::InvalidIssueError + when Gitlab::Email::InvalidNoteError, + Gitlab::Email::InvalidIssueError can_retry = true reason = e.message else |