don't participate own posts on creation

This commit is contained in:
Benjamin Neff 2016-06-18 06:21:14 +02:00
parent f58167c154
commit 70f378a1c1
2 changed files with 2 additions and 4 deletions

View file

@ -54,7 +54,6 @@ class StatusMessageCreationService
def process(status_message, aspect_ids, services)
add_to_streams(status_message, aspect_ids) unless status_message.public
dispatch(status_message, services)
user.participate!(status_message)
end
def add_to_streams(status_message, aspect_ids)

View file

@ -190,11 +190,10 @@ describe StatusMessagesController, :type => :controller do
expect(StatusMessage.first.provider_display_name).to eq('mobile')
end
it "has one participation" do
it "has no participation" do
post :create, status_message_hash
new_message = StatusMessage.find_by_text(text)
expect(new_message.participations.count).to eq(1)
expect(new_message.participations.first.count).to eq(1)
expect(new_message.participations.count).to eq(0)
end
context 'with photos' do