Merge remote-tracking branch 'upstream/pull/5465'
This commit is contained in:
commit
af9d4f2696
2 changed files with 2 additions and 2 deletions
|
@ -49,7 +49,7 @@ class MessagesController < ApplicationController
|
||||||
elsif @message.save
|
elsif @message.save
|
||||||
flash[:notice] = t ".message_sent"
|
flash[:notice] = t ".message_sent"
|
||||||
UserMailer.message_notification(@message).deliver_later if @message.notify_recipient?
|
UserMailer.message_notification(@message).deliver_later if @message.notify_recipient?
|
||||||
redirect_to messages_inbox_path
|
redirect_to messages_outbox_path
|
||||||
else
|
else
|
||||||
@title = t "messages.new.title"
|
@title = t "messages.new.title"
|
||||||
render :action => "new"
|
render :action => "new"
|
||||||
|
|
|
@ -163,7 +163,7 @@ class MessagesControllerTest < ActionDispatch::IntegrationTest
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
assert_redirected_to messages_inbox_path
|
assert_redirected_to messages_outbox_path
|
||||||
assert_equal "Message sent", flash[:notice]
|
assert_equal "Message sent", flash[:notice]
|
||||||
e = ActionMailer::Base.deliveries.first
|
e = ActionMailer::Base.deliveries.first
|
||||||
assert_equal [recipient_user.email], e.to
|
assert_equal [recipient_user.email], e.to
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue