Merge pull request #4273 from mpalmer/log-useful-info-replyusernotmatchingerror

Log some useful info when raising ReplyUserNotMatchingError
This commit is contained in:
Matt Palmer 2016-06-17 12:06:03 +10:00 committed by GitHub
commit fde5ef4902

View file

@ -126,7 +126,9 @@ module Email
when :reply
email_log = destination[:obj]
raise ReplyUserNotMatchingError if email_log.user_id != user.id
if email_log.user_id != user.id
raise ReplyUserNotMatchingError, "email_log.user_id => #{email_log.user_id.inspect}, user.id => #{user.id.inspect}"
end
create_reply(user: user,
raw: body,