Upgrade download datafiles if doesn't exist (#1254)

This commit is contained in:
AlteredCoder 2022-02-14 16:51:06 +01:00 committed by GitHub
parent 5a0843852a
commit 8b90f4b2b2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 8 deletions

View file

@ -259,10 +259,11 @@ func UpgradeConfig(itemType string, name string, force bool) {
if v.UpToDate {
log.Infof("%s : up-to-date", v.Name)
if err = cwhub.DownloadDataIfNeeded(csConfig.Hub, v, force); err != nil {
log.Fatalf("%s : download failed : %v", v.Name, err)
}
if !force {
if err = cwhub.DownloadDataIfNeeded(csConfig.Hub, v, false); err != nil {
log.Fatalf("%s : download failed : %v", v.Name, err)
}
continue
}
}