mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00
[ruby/fileutils] If noop
, return before checking the argument
Get rid of failure in rbs.
e44b7b366c
This commit is contained in:
parent
eeb682c51b
commit
7725442022
1 changed files with 1 additions and 1 deletions
|
@ -733,6 +733,7 @@ module FileUtils
|
|||
def ln_sr(src, dest, target_directory: true, force: nil, noop: nil, verbose: nil)
|
||||
fu_output_message "ln -sr#{force ? 'f' : ''}#{
|
||||
target_directory ? '' : 'T'} #{[src,dest].flatten.join ' '}" if verbose
|
||||
return if noop
|
||||
unless target_directory
|
||||
destdirs = fu_split_path(File.realdirpath(dest))
|
||||
end
|
||||
|
@ -754,7 +755,6 @@ module FileUtils
|
|||
end
|
||||
s = File.join(*base, *srcdirs)
|
||||
end
|
||||
next if noop
|
||||
remove_file d, true if force
|
||||
File.symlink s, d
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue