Public: anyone can read this; the crew can change it.

Migrated from github.com/Trevato/SO-ARM100

Relay's POST /admin actions (save, mod-add, mod-remove, pause, resume, end, take) are handled in src/admin-routes.ts - no behaviour change #169

opened this

Merged 43d 8h ago

POST /admin handling now lives in src/admin-routes.ts as handleAdmin(lobby, req, res, url, readBody), with no behaviour change. It carries the 16 KiB form limit and all seven actions: save, mod-add, mod-remove, pause, resume, end and take.

Notes

opened this

POST /admin handling now lives in src/admin-routes.ts as handleAdmin(lobby, req, res, url, readBody), with no behaviour change. It carries the 16 KiB form limit and all seven actions: save, mod-add, mod-remove, pause, resume, end and take.

relay.ts no longer has the admin handler, the MAX_FORM constant or the AdminError/changeFromForm imports. It keeps one call, handleAdmin(..., readBody), and passes its own readBody so the body-reading logic stays in one place.

admin-relay.test.ts, relay.test.ts and admin.test.ts pass untouched: 26 pass, 0 fail.

bun x tsc --noEmit still reports one error, in src/ui/metrics-panel.js(11,64). It appears the same with my change stashed, so it isn't from this change. I left it alone.

Closes #122

Sign in to join this conversation.

Search
↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs