mirror of
https://github.com/rclone/rclone.git
synced 2025-01-24 12:56:36 +02:00
http: ensure folders show the modtime configured by --default-time #6986
This commit is contained in:
parent
84281c9089
commit
d379641021
@ -495,7 +495,7 @@ func (f *Fs) List(ctx context.Context, dir string) (entries fs.DirEntries, err e
|
|||||||
add(file)
|
add(file)
|
||||||
case fs.ErrorNotAFile:
|
case fs.ErrorNotAFile:
|
||||||
// ...found a directory not a file
|
// ...found a directory not a file
|
||||||
add(fs.NewDir(remote, timeUnset))
|
add(fs.NewDir(remote, time.Time{}))
|
||||||
default:
|
default:
|
||||||
fs.Debugf(remote, "skipping because of error: %v", err)
|
fs.Debugf(remote, "skipping because of error: %v", err)
|
||||||
}
|
}
|
||||||
@ -507,7 +507,7 @@ func (f *Fs) List(ctx context.Context, dir string) (entries fs.DirEntries, err e
|
|||||||
name = strings.TrimRight(name, "/")
|
name = strings.TrimRight(name, "/")
|
||||||
remote := path.Join(dir, name)
|
remote := path.Join(dir, name)
|
||||||
if isDir {
|
if isDir {
|
||||||
add(fs.NewDir(remote, timeUnset))
|
add(fs.NewDir(remote, time.Time{}))
|
||||||
} else {
|
} else {
|
||||||
in <- remote
|
in <- remote
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user