Skip to content

Commit

Permalink
Change error prefix to RSMErrorYahoo, change error msg substring to '…
Browse files Browse the repository at this point in the history
…over the limit'
  • Loading branch information
Sergei Epatov committed Feb 1, 2016
1 parent d01b7c3 commit cd9a226
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/core/abstract/MCMessageConstants.h
Original file line number Diff line number Diff line change
Expand Up @@ -253,8 +253,8 @@ namespace mailcore {
ErrorServerDate,
ErrorNoValidServerFound,
ErrorCustomCommand,
ErrorSendMessageSpamSuspected,
ErrorSendMessageDailyLimitExceeded
ErrorYahooSendMessageSpamSuspected,
ErrorYahooSendMessageDailyLimitExceeded
};

enum PartType {
Expand Down
6 changes: 3 additions & 3 deletions src/core/smtp/MCSMTPSession.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -682,12 +682,12 @@ void SMTPSession::sendMessage(Address * from, Array * recipients, Data * message
goto err;
}
}
else if (responseCode == 521 && response->locationOfString(MCSTR("limit")) != -1) {
* pError = ErrorSendMessageDailyLimitExceeded;
else if (responseCode == 521 && response->locationOfString(MCSTR("over the limit")) != -1) {
* pError = ErrorYahooSendMessageDailyLimitExceeded;
goto err;
}
else if (responseCode == 554 && response->locationOfString(MCSTR("spam")) != -1) {
* pError = ErrorSendMessageSpamSuspected;
* pError = ErrorYahooSendMessageSpamSuspected;
goto err;
}

Expand Down
4 changes: 2 additions & 2 deletions src/objc/abstract/MCOConstants.h
Original file line number Diff line number Diff line change
Expand Up @@ -414,9 +414,9 @@ typedef NS_ENUM(NSInteger, MCOErrorCode) {
/** Error while running custom command */
MCOErrorCustomCommand,
/** Spam was suspected by server */
MCOErrorSendMessageSpamSuspected,
MCOErrorYahooSendMessageSpamSuspected,
/** Daily limit of sent messages was hit */
MCOErrorSendMessageDailyLimitExceeded,
MCOErrorYahooSendMessageDailyLimitExceeded,
/** The count of all errors */
MCOErrorCodeCount,
};
Expand Down

0 comments on commit cd9a226

Please sign in to comment.