File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -647,13 +647,6 @@ diff_trace_origin(struct view *view, struct line *line)
647647 struct blame_header header ;
648648 struct blame_commit commit ;
649649
650- if (!commit_line ) {
651- report ("Failed to read the commit ID" );
652- return REQ_NONE ;
653- }
654-
655- string_copy_rev_from_commit_line (id , box_text (commit_line ));
656-
657650 if (!diff || !chunk || chunk == line || diff < commit_line ) {
658651 report ("The line to trace must be inside a diff chunk" );
659652 return REQ_NONE ;
@@ -695,6 +688,11 @@ diff_trace_origin(struct view *view, struct line *line)
695688 }
696689 }
697690
691+ if (commit_line )
692+ string_copy_rev_from_commit_line (id , box_text (commit_line ));
693+ else
694+ string_copy (id , view -> vid );
695+
698696 if (chunk_marker == '-' )
699697 string_format (ref , "%s^" , id );
700698 else
You can’t perform that action at this time.
0 commit comments