Skip to content

Commit 2cd8248

Browse files
always download the index the first time
Co-authored-by: Alessio Perugini <[email protected]>
1 parent 814377f commit 2cd8248

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

index/index.go

+2-5
Original file line numberDiff line numberDiff line change
@@ -70,11 +70,8 @@ func Init(indexString string, directory *paths.Path) *Resource {
7070
IndexSignature: *directory.Join(signatureFile),
7171
}
7272

73-
if !ir.IndexFile.Exist() || time.Since(ir.LastRefresh) > 1*time.Hour {
74-
// Download the file again and save it
75-
if err := ir.DownloadAndVerify(); err != nil {
76-
log.Fatalf("cannot download index: %s", err)
77-
}
73+
if err := ir.DownloadAndVerify(); err != nil {
74+
log.Fatalf("cannot download index: %s", err)
7875
}
7976

8077
return &ir

0 commit comments

Comments
 (0)