update cart
Build and Publish / BuildAndDeployArm64 (push) Failing after 5s
Build and Publish / BuildAndDeployAmd64 (push) Has been cancelled

This commit is contained in:
2026-06-17 14:16:25 +02:00
parent 11be8aec56
commit ad410d217c
11 changed files with 257 additions and 41 deletions
+8
View File
@@ -71,6 +71,14 @@ func (sf *StateFile) GetVoucher(code string) (*Voucher, bool) {
func LoadStateFile(fileName string) (*StateFile, error) {
f, err := os.Open(fileName)
if err != nil {
if os.IsNotExist(err) {
return &StateFile{
State: State{
Vouchers: []Voucher{},
},
Version: 1,
}, nil
}
return nil, err
}
defer f.Close()