1
0
mirror of https://github.com/amir20/dozzle.git synced 2025-12-24 06:28:42 +01:00

fix: fixes profile disk configuration when pinned is an empty set (#2570)

This commit is contained in:
Amir Raminfar
2023-12-07 08:05:19 -08:00
committed by GitHub
parent 185538b794
commit 2fbb65c921

View File

@@ -36,7 +36,7 @@ type Settings struct {
type Profile struct {
Settings *Settings `json:"settings,omitempty"`
Pinned []string `json:"pinned,omitempty"`
Pinned []string `json:"pinned"`
VisibleKeys map[string][][]string `json:"visibleKeys,omitempty"`
ReleaseSeen string `json:"releaseSeen,omitempty"`
}
@@ -123,5 +123,9 @@ func Load(user auth.User) (Profile, error) {
return Profile{}, err
}
if profile.Pinned == nil {
profile.Pinned = []string{}
}
return profile, nil
}