Commit 7d1b3d4e authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Fix passign full user object instead of id to Event.create

parent 6579ba3e
...@@ -33,7 +33,7 @@ class ActivityObserver < BaseObserver ...@@ -33,7 +33,7 @@ class ActivityObserver < BaseObserver
target_id: record.id, target_id: record.id,
target_type: record.class.name, target_type: record.class.name,
action: status, action: status,
author_id: current_user author_id: current_user.id
) )
end end
end end
...@@ -46,7 +46,7 @@ class MergeRequestObserver < ActivityObserver ...@@ -46,7 +46,7 @@ class MergeRequestObserver < ActivityObserver
target_id: record.id, target_id: record.id,
target_type: record.class.name, target_type: record.class.name,
action: status, action: status,
author_id: current_user author_id: current_user.id
) )
end end
end end
...@@ -8,7 +8,6 @@ describe ActivityObserver do ...@@ -8,7 +8,6 @@ describe ActivityObserver do
it { @event.project.should == project } it { @event.project.should == project }
end end
describe "Issue created" do describe "Issue created" do
before do before do
Issue.observers.enable :activity_observer do Issue.observers.enable :activity_observer do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment