aboutsummaryrefslogtreecommitdiff
path: root/internal/admin/id_alloc.go
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-09-16 17:05:17 -0400
committerhistoria <[not public]>2026-09-16 17:05:17 -0400
commit1dad15698845d370e998f7cc5feb8aece3fab58f (patch)
tree8d58058782de9f422573e1f8efd5d130ce7d1ce9 /internal/admin/id_alloc.go
parenta6cf03a6ae98e4fb675da25046d148e92bcf7206 (diff)
downloadthehouseoficarus-1dad15698845d370e998f7cc5feb8aece3fab58f.tar.gz
refactor: remove dead code, consolidate save/error handling, add lint gate
Diffstat (limited to 'internal/admin/id_alloc.go')
-rw-r--r--internal/admin/id_alloc.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/admin/id_alloc.go b/internal/admin/id_alloc.go
index 3a3c973..83ca89c 100644
--- a/internal/admin/id_alloc.go
+++ b/internal/admin/id_alloc.go
@@ -13,7 +13,7 @@ import (
// collide with an ID that lives in a different subdirectory. The starting point
// is the local subdir's minimum existing ID (clustering), then the first
// globally-free ID scanning upward.
-func (s *AdminServer) nextRoomID(fromRoomID int) (int, string, error) {
+func (s *AdminServer) nextRoomID(fromRoomID int) (int, string) {
base := filepath.Join(s.dataDir, "rooms")
subdir, err := findRoomSubdir(base, fromRoomID)
if err != nil {
@@ -46,7 +46,7 @@ func (s *AdminServer) nextRoomID(fromRoomID int) (int, string, error) {
for used[id] {
id++
}
- return id, subdir, nil
+ return id, subdir
}
func findRoomSubdir(base string, roomID int) (string, error) {