fix: rename func param
parent
592606a00d
commit
267c9a42e0
|
@ -318,14 +318,14 @@ func checkParent(src, dst string) error {
|
||||||
|
|
||||||
// Checks if path contains symlink to out-of-scope targets.
|
// Checks if path contains symlink to out-of-scope targets.
|
||||||
// Returns error ErrNotExist if it does.
|
// Returns error ErrNotExist if it does.
|
||||||
func checkOutOfScopeSymlink(d *data, path string) error {
|
func checkOutOfScopeSymlink(d *data, target string) error {
|
||||||
lsf, ok := d.user.Fs.(afero.LinkReader)
|
lsf, ok := d.user.Fs.(afero.LinkReader)
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
var parts []string
|
var parts []string
|
||||||
for _, part := range strings.Split(path, string(os.PathSeparator)) {
|
for _, part := range strings.Split(target, string(os.PathSeparator)) {
|
||||||
if part != "" {
|
if part != "" {
|
||||||
parts = append(parts, part)
|
parts = append(parts, part)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue