Commit Graph

7 Commits

Author SHA1 Message Date
Houmgaor
5f3c843082 refactor(config): eliminate ErupeConfig global variable
Replace the mutable global `_config.ErupeConfig` with dependency
injection across 79 files. Config is now threaded through existing
paths: `ClientContext.RealClientMode` for packet encoding, `s.server.
erupeConfig` for channel handlers, and explicit parameters for utility
functions. This removes hidden coupling, enables test parallelism
without global save/restore, and prevents low-level packages from
reaching up to the config layer.

Key changes:
- Enrich ClientContext with RealClientMode for packet files
- Add mode parameter to CryptConn, mhfitem, mhfcourse functions
- Convert handlers_commands init() to lazy sync.Once initialization
- Delete global var, init(), and helper functions from config.go
- Update all tests to pass config explicitly
2026-02-20 17:07:42 +01:00
Houmgaor
c64dabc3ba fix: check all Close() return values for errcheck lint
Add explicit error discards (_ =) for Close() calls on network
connections, SQL rows, and file handles across 28 files. Also add
.golangci.yml with standard linter defaults to match CI configuration.
2026-02-17 23:57:14 +01:00
Houmgaor
fc6e479df9 fix(lint): fixing more complex formatters problems. 2025-10-19 22:46:21 +02:00
wish
b4df642ee3 add ClientMode config option 2023-06-18 20:31:18 +10:00
wish
dcab41a6c7 rework logging code 2023-03-09 22:05:32 +11:00
wish
5e42402a3d signserver cleanup 2022-10-18 11:42:12 +11:00
wish
2c0e7a5267 repository cleanup 2022-07-29 03:25:23 +10:00