txAdmin icon indicating copy to clipboard operation
txAdmin copied to clipboard

[BUG] Warn localization not working if menu is disabled

Open manzarek123 opened this issue 2 years ago • 2 comments

txAdmin/FXServer versions: 4.13.3/5429

Describe the bug Localization is not working for Warns when menu is disabled in TxAdmin config

To Reproduce Steps to reproduce the behavior:

  1. Set Langage to French in Settings->Global
  2. Enable the Menu in Settings->Menu
  3. Restart Server
  4. Warn a player => NUI Warn menu is in French
  5. Disable the Menu in Settings->Menu
  6. Restart Server
  7. Warn a player => NUI Warn menu is in English

Expected behavior Warns to be in the correct langage with Menu Disabled

manzarek123 avatar Mar 25 '22 22:03 manzarek123

Confirmed.
Related to #608.

tabarra avatar Mar 26 '22 08:03 tabarra

The bug can most likely be attributed to improper ServerCtx event listener logic for clients when the menu is disabled. During local testing with the menu disabled, clients never receive the "setServerCtx" event upon update of web settings. ServerCtx is updated within GlobalState but the event is never properly dispatched to clients, as we never populate the TX_ADMINS table when the menu is disabled.

Here is where its blowing up

In fact, after glancing over some of the code, does localization even work in NUI for servers that don't enable OneSync?

TasoOneAsia avatar May 20 '22 02:05 TasoOneAsia

Confirmed that this is still a thing in v5, even though #608 was fixed some time ago :(

tabarra avatar Nov 21 '22 06:11 tabarra

Issue finally fixed.
Will be available on the next update.

tabarra avatar Feb 25 '24 05:02 tabarra