aboutsummaryrefslogtreecommitdiff
path: root/internal/admin/api_techs.go
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-07-01 22:30:31 -0400
committerhistoria <[not public]>2026-07-01 22:30:31 -0400
commitc14c2e403c75a913e1a6d962fb6fe64f013adae5 (patch)
tree75070293fe2535b594ac72e501cbf08a3f1146e0 /internal/admin/api_techs.go
parent8eec7b75ff9c8c368b252373db45fb891732d2ca (diff)
downloadthehouseoficarus-c14c2e403c75a913e1a6d962fb6fe64f013adae5.tar.gz
fix: combat formulas and mob attack types (mobs switch attack styles if safespotting)
Diffstat (limited to 'internal/admin/api_techs.go')
-rw-r--r--internal/admin/api_techs.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/admin/api_techs.go b/internal/admin/api_techs.go
index bdb8295..0d3e201 100644
--- a/internal/admin/api_techs.go
+++ b/internal/admin/api_techs.go
@@ -25,8 +25,8 @@ func (s *AdminServer) handleTechs(w http.ResponseWriter, r *http.Request) {
writeJSON(w, map[string]any{"error": "invalid json"})
return
}
- id, _ := m["id"].(string)
- if strings.TrimSpace(id) == "" {
+ id, ok := m["id"].(string)
+ if !ok || strings.TrimSpace(id) == "" {
writeJSON(w, map[string]any{"error": "missing id"})
return
}