Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[MIRROR] Fixes source of tgui errors in accounts console [MDB IGNORE]…
… (#24412) * Fixes source of tgui errors in accounts console (#79048) ## About The Pull Request It's possible to have bank accounts created with `null` jobs. This results in a runtime bluescreen that breaks the account management console for the whole round. <details><summary>Not ideal</summary> ![lKCRwKfZ6M](https://github.com/tgstation/tgstation/assets/13398309/e91fa68b-b1d2-437e-b77d-e7144618b2f8) ![Code_85omxswUqx](https://github.com/tgstation/tgstation/assets/13398309/c97d1ef2-4138-4cff-bdc5-0d9a1f185ba2) </details> The runtime comes from trying to access `title` from the null job datum in `ui_data()` which results in the ui data not being sent. https://github.com/tgstation/tgstation/blob/c10bf15c4a9b71eec325ea2f201a68defb80943b/code/game/machinery/computer/accounting.dm#L22-L29 --- This PR just guards against that. Similar patterns can be seen everywhere else where this data is accessed. <details><summary> For example</summary> ![image](https://github.com/tgstation/tgstation/assets/13398309/590adb03-9023-4661-93fd-ff68fb24b3f7) ![image](https://github.com/tgstation/tgstation/assets/13398309/0603a442-617f-4cb4-bc24-2561855a64d9) </details> ## Why It's Good For The Game More robust code, less console becoming unusable. ## Changelog :cl: fix: fixes a tgui bluescreen bug with the bank account console that can occur when there is bad bank account data /:cl: * Fixes source of tgui errors in accounts console --------- Co-authored-by: Bloop <[email protected]>
- Loading branch information