Skip to content

Commit 4cbe92f

Browse files
Stefan Mochgitster
authored andcommitted
mv: remove unneeded 'if (!show_only)'
Commit a127331 (mv: allow moving nested submodules, 2016-04-19), introduced if (show_only) continue; in this for-loop before if (!show_only) which became redundant, because it is now always true. Signed-off-by: Stefan Moch <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 36b78cd commit 4cbe92f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

builtin/mv.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -287,8 +287,7 @@ int cmd_mv(int argc, const char **argv, const char *prefix)
287287

288288
pos = cache_name_pos(src, strlen(src));
289289
assert(pos >= 0);
290-
if (!show_only)
291-
rename_cache_entry_at(pos, dst);
290+
rename_cache_entry_at(pos, dst);
292291
}
293292

294293
if (gitmodules_modified)

0 commit comments

Comments
 (0)