mirror of
https://github.com/rclone/rclone.git
synced 2024-11-22 08:23:47 +01:00
union: the root folder shows the modtime configured by --default-time #6986
This commit is contained in:
parent
f7b87a8049
commit
6001f05a12
@ -3,7 +3,6 @@ package policy
|
|||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"math/rand"
|
|
||||||
"path"
|
"path"
|
||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
@ -109,9 +108,7 @@ func findEntry(ctx context.Context, f fs.Fs, remote string) fs.DirEntry {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
// random modtime for root
|
return fs.NewDir("", time.Time{})
|
||||||
randomNow := time.Unix(time.Now().Unix()-rand.Int63n(10000), 0)
|
|
||||||
return fs.NewDir("", randomNow)
|
|
||||||
}
|
}
|
||||||
found := false
|
found := false
|
||||||
for _, e := range entries {
|
for _, e := range entries {
|
||||||
|
Loading…
Reference in New Issue
Block a user