mirror of
https://github.com/safing/portmaster
synced 2025-09-01 18:19:12 +00:00
Download update index if not available
This commit is contained in:
parent
2bc0da6700
commit
f3b5cb89ce
2 changed files with 8 additions and 2 deletions
2
main.go
2
main.go
|
@ -31,7 +31,7 @@ func init() {
|
|||
func main() {
|
||||
|
||||
// Set Info
|
||||
info.Set("Portmaster", "0.3.1", "AGPLv3", true)
|
||||
info.Set("Portmaster", "0.3.2", "AGPLv3", true)
|
||||
|
||||
// Start
|
||||
err := modules.Start()
|
||||
|
|
|
@ -61,7 +61,13 @@ func start() error {
|
|||
err = LoadIndexes()
|
||||
if err != nil {
|
||||
if os.IsNotExist(err) {
|
||||
log.Infof("updates: stable.json does not yet exist, waiting for first update cycle")
|
||||
// download indexes
|
||||
log.Infof("updates: downloading update index...")
|
||||
|
||||
err = UpdateIndexes()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
} else {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue