Skip to content

Commit d039acd

Browse files
committed
create_symlink: trap impossible inputs
1 parent 013df59 commit d039acd

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

+stdlib/create_symlink.m

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,7 @@
1616

1717
ok = false;
1818

19-
if stdlib.is_url(target) || stdlib.is_url(link), return; end
20-
21-
if stdlib.exists(link), return, end
19+
if stdlib.exists(link) || ~stdlib.exists(target) || stdlib.is_url(link), return, end
2220

2321
try
2422
createSymbolicLink(link, target);

0 commit comments

Comments
 (0)