summaryrefslogtreecommitdiff
path: root/app/models/note.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/note.rb')
-rw-r--r--app/models/note.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/models/note.rb b/app/models/note.rb
index e3c571a1574..99e86ac0250 100644
--- a/app/models/note.rb
+++ b/app/models/note.rb
@@ -290,7 +290,7 @@ class Note < ActiveRecord::Base
# +mentioner+.
def noteable_project_id(noteable, mentioning_project)
if noteable.is_a?(Commit)
- if mentioning_project.repository.commit(noteable.id)
+ if mentioning_project.commit(noteable.id)
# The noteable commit belongs to the mentioner's project
mentioning_project.id
else
@@ -512,7 +512,7 @@ class Note < ActiveRecord::Base
# override to return commits, which are not active record
def noteable
if for_commit?
- project.repository.commit(commit_id)
+ project.commit(commit_id)
else
super
end