mirror of
https://github.com/nesquena/hermes-webui.git
synced 2026-07-16 04:30:17 +00:00
8da96a84d3
The initial fix added ~16 lines to server.py, tripping test_server_py_under_750_lines (server.py must stay a thin dispatcher; logic belongs in api/). Moved the whole preflight-response into apply_cors_preflight_headers(handler) in api/routes.py; server.py's do_OPTIONS is now a 4-line dispatcher. server.py 764 -> 746 lines. Same security behavior (same-origin/allowlist echo, Vary: Origin, no wildcard, header-less denial); test rewritten to the header-emitting API + added Vary and no-header-on-denial assertions and a routes.py wildcard regression guard.