diff options
author | Benjamin Neff <benjamin@coding4coffee.ch> | 2016-06-10 22:58:45 +0300 |
---|---|---|
committer | Benjamin Neff <benjamin@coding4coffee.ch> | 2016-06-26 07:21:01 +0300 |
commit | ae05d4e92857e14c64fcd2fc233dec19922ccd2b (patch) | |
tree | 191f7c9bd5d8734a6959381751c6b0154d6c93f4 /app/controllers | |
parent | b0942bc2193b524f36c4526c6bd51419661c0388 (diff) |
use Diaspora::Federation::Dispatcher everywhere
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/conversations_controller.rb | 2 | ||||
-rw-r--r-- | app/controllers/messages_controller.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/conversations_controller.rb b/app/controllers/conversations_controller.rb index f1266f3ad..c765f4e01 100644 --- a/app/controllers/conversations_controller.rb +++ b/app/controllers/conversations_controller.rb @@ -45,7 +45,7 @@ class ConversationsController < ApplicationController @response = {} if person_ids.present? && @conversation.save - Postzord::Dispatcher.build(current_user, @conversation).post + Diaspora::Federation::Dispatcher.defer_dispatch(current_user, @conversation) @response[:success] = true @response[:message] = I18n.t('conversations.create.sent') @response[:conversation_id] = @conversation.id diff --git a/app/controllers/messages_controller.rb b/app/controllers/messages_controller.rb index e0b32f671..fc6aacc16 100644 --- a/app/controllers/messages_controller.rb +++ b/app/controllers/messages_controller.rb @@ -17,7 +17,7 @@ class MessagesController < ApplicationController if message.save logger.info "event=create type=comment user=#{current_user.diaspora_handle} status=success " \ "message=#{message.id} chars=#{params[:message][:text].length}" - Postzord::Dispatcher.build(current_user, message).post + Diaspora::Federation::Dispatcher.defer_dispatch(current_user, message) else flash[:error] = I18n.t('conversations.new_conversation.fail') end |