diff options
Diffstat (limited to 'app/models/legacy_diff_note.rb')
-rw-r--r-- | app/models/legacy_diff_note.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/models/legacy_diff_note.rb b/app/models/legacy_diff_note.rb index bbb9f2346eb..f15553d706e 100644 --- a/app/models/legacy_diff_note.rb +++ b/app/models/legacy_diff_note.rb @@ -85,7 +85,7 @@ class LegacyDiffNote < Note return nil unless noteable return @diff if defined?(@diff) - @diff = noteable.diffs(Commit.max_diff_options).find do |d| + @diff = noteable.raw_diffs(Commit.max_diff_options).find do |d| d.new_path && Digest::SHA1.hexdigest(d.new_path) == diff_file_hash end end @@ -116,7 +116,7 @@ class LegacyDiffNote < Note # Find the diff on noteable that matches our own def find_noteable_diff - diffs = noteable.diffs(Commit.max_diff_options) + diffs = noteable.raw_diffs(Commit.max_diff_options) diffs.find { |d| d.new_path == self.diff.new_path } end end |