fix: remove unused config struct key, fix local aliases parsing error

This commit is contained in:
2024-10-04 17:13:47 +00:00
parent 5a90dd8377
commit 91c396dd68
8 changed files with 70 additions and 45 deletions
+4 -3
View File
@@ -34,13 +34,14 @@ func (b *Buckets) GetAll(w http.ResponseWriter, r *http.Request) {
return
}
var bucket schema.Bucket
if err := json.Unmarshal(body, &bucket); err != nil {
var data schema.Bucket
if err := json.Unmarshal(body, &data); err != nil {
ch <- schema.Bucket{ID: bucket.ID, GlobalAliases: bucket.GlobalAliases}
return
}
ch <- bucket
data.LocalAliases = bucket.LocalAliases
ch <- data
}()
}