Make Note methods saner
This commit is contained in:
parent
db3d90cbcb
commit
b1461de993
7 changed files with 39 additions and 18 deletions
|
@ -13,9 +13,7 @@ module NotesHelper
|
|||
end
|
||||
|
||||
def link_to_commit_diff_line_note(note)
|
||||
return unless note.line_note?
|
||||
|
||||
commit = note.target
|
||||
commit = note.noteable
|
||||
diff_index, diff_old_line, diff_new_line = note.line_code.split('_')
|
||||
|
||||
link_file = commit.diffs[diff_index.to_i].new_path
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue