- Remove locale check for give command (Now handled in the localeService itself)
- Fix variable names/spelling/lowercase in LocaleService.getPlatformForServerLocale (should be no change in behaviour)
- Rewrite LocaleService.getPlatformForClientLocale to not depend on serverSupportedLocales, and instead just use the tables for validity checking
- Expand fallback of client locale handling to include the region code (Handles Czech and Korean locales)
- Write tests for locales
Co-authored-by: DrakiaXYZ <565558+TheDgtl@users.noreply.github.com>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/332
Co-authored-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
Co-committed-by: DrakiaXYZ <drakiaxyz@noreply.dev.sp-tarkov.com>
I don't want em'. Grumble. Ahem...
This change allows for "extra" parentheses to be added in situations where, without them, the code could possibly, potentially be seen as maybe a little-bit, tiny confusing.
Also, fixes a bunch of other ESLint errors. Mostly down to naming warnings now. Mostly.
I'm currently hosting the Project Fika Docker on a dedicated Server to have the Server up 24/7 without the need to let my PC run.
When hosting this as a docker container behind traefik (reverse proxy), the logger currently logs the internal IP of the traefik container.
This change makes it so that the headers that traefik/nginx can set are actually read and used. If these headers are not present, we fall back to the original method of using the `socket.remoteAdress`.
Since this is for logging only, the security implications are minimal.
Co-authored-by: Vincent Niehues <vincent.niehues@zeitag.ch>
Reviewed-on: https://dev.sp-tarkov.com/SPT-AKI/Server/pulls/329
Co-authored-by: vniehues <vniehues@noreply.dev.sp-tarkov.com>
Co-committed-by: vniehues <vniehues@noreply.dev.sp-tarkov.com>
Comment changes
Variable change
Only log debug message when default mod not found + multiple choices exist in pool
Fixed possible nullref if `getMatchingPreset()` returns null
This is the first pass of ESLint on the codebase.
ESLint formatting is less strict when it comes to line-length and line-breaks then dprint/biome, so if you see formatting that you don't like... fix it! It shouldn't require a configuration change.
- This should merge clean into master (when the time comes).
- This will not merge clean into `3.9.0-DEV`, but the conflicts aren't that bad.
The built-in ESLint import settings will lint the imports, but not fix them, as that's concidered stylistic. The ESLint Stylistic package doesn't currently support sorting. We have to use the ESLint Import plugin to force import sorting. This Import plugin doesn't yet support the new ESLint flat-configuration file format so we've had to convert back to the old no-flat format.