Skip to content

Commit 731eb17

Browse files
sschuberthgitster
authored andcommitted
submodule: remove a superfluous second check for the "new" variable
Signed-off-by: Sebastian Schuberth <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 2580491 commit 731eb17

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

submodule.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1362,8 +1362,7 @@ int submodule_move_head(const char *path,
13621362
cp1.no_stdin = 1;
13631363
cp1.dir = path;
13641364

1365-
argv_array_pushl(&cp1.args, "update-ref", "HEAD",
1366-
new ? new : EMPTY_TREE_SHA1_HEX, NULL);
1365+
argv_array_pushl(&cp1.args, "update-ref", "HEAD", new, NULL);
13671366

13681367
if (run_command(&cp1)) {
13691368
ret = -1;

0 commit comments

Comments
 (0)