forked from TrueCloudLab/rclone
azureblob: Read LastModified time of containers in root listing
This commit is contained in:
parent
d54fca4e58
commit
2870874329
1 changed files with 6 additions and 1 deletions
|
@ -422,7 +422,12 @@ func (f *Fs) listContainers(dir string) (entries fs.DirEntries, err error) {
|
||||||
return nil, fs.ErrorListBucketRequired
|
return nil, fs.ErrorListBucketRequired
|
||||||
}
|
}
|
||||||
err = f.listContainersToFn(func(container *storage.Container) error {
|
err = f.listContainersToFn(func(container *storage.Container) error {
|
||||||
d := fs.NewDir(container.Name, time.Time{})
|
t, err := time.Parse(time.RFC1123, container.Properties.LastModified)
|
||||||
|
if err != nil {
|
||||||
|
fs.Debugf(f, "Failed to parse LastModified %q: %v", container.Properties.LastModified, err)
|
||||||
|
t = time.Time{}
|
||||||
|
}
|
||||||
|
d := fs.NewDir(container.Name, t)
|
||||||
entries = append(entries, d)
|
entries = append(entries, d)
|
||||||
return nil
|
return nil
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue