update
Some checks failed
Build and Publish / Metadata (push) Successful in 16s
Build and Publish / BuildAndDeployAmd64 (push) Successful in 1m0s
Build and Publish / BuildAndDeployArm64 (push) Has been cancelled

This commit is contained in:
2025-11-13 21:52:29 +01:00
parent af5d4cd325
commit e25ca3304e
7 changed files with 110 additions and 37 deletions

View File

@@ -43,7 +43,7 @@ func (srv *Server) getInventoryHandler(w http.ResponseWriter, r *http.Request) {
sku := inventory.SKU(parts[1])
locationID := inventory.LocationID(parts[2])
quantity, err := srv.service.GetInventory(sku, locationID)
quantity, err := srv.service.GetInventory(r.Context(), sku, locationID)
if err != nil {
http.Error(w, err.Error(), http.StatusInternalServerError)
return
@@ -81,7 +81,7 @@ func main() {
Mode: maintnotifications.ModeDisabled,
},
})
s, err := inventory.NewRedisInventoryService(rdb, ctx)
s, err := inventory.NewRedisInventoryService(rdb)
if err != nil {
log.Fatalf("Unable to connect to inventory redis: %v", err)
return