v2.0.8 #156

Merged
PxlLoewe merged 24 commits from staging into release 2026-01-31 22:08:50 +00:00
PxlLoewe commented 2026-01-31 22:08:34 +00:00 (Migrated from github.com)

This pull request introduces significant refactoring and improvements to permission handling for banned users, as well as major UI simplifications and code deduplication in the dispatch and pilot applications. The most important changes are grouped below by backend logic and frontend/UI improvements.

Backend: Permission Handling and Helper Refactoring

  • Improved logic for removing and restoring Discord roles for users with penalties, now tracking which permissions have been applied and restoring roles when bans expire or are suspended. Also, the function is now called on a schedule and at startup. [1] [2] [3]
  • Refactored setUserStandardNamePermissions into a reusable helper function, and updated its usage in both route handlers and the backend penalty logic. [1] [2]
  • Improved member fetching logic to ensure correct retrieval from cache or Discord API.

Frontend/UI: Navbar and Layout Refactoring

  • Consolidated and simplified the Navbar components for both the dispatch and pilot apps, moving shared logic to a single Navbar component and passing children for custom controls, reducing code duplication. [1] [2] [3] [4] [5] [6] [7]
  • Updated the Mode Switch Dropdown to support more flexible styling and added a direct link to the HUB. [1] [2]
  • Removed unused or redundant theme switch components from both dispatch and pilot navbars.
  • Fixed import paths after moving and renaming the Connection component.

Other Improvements

  • Set the HOST environment variable in Dockerfiles for both the dispatch and hub apps to ensure proper network binding. [1] [2]
  • Minor UI and query cleanups in the hub application for event and path selection components. [1] [2] [3]

These changes improve maintainability, reliability of permission handling, and consistency across the frontend.

This pull request introduces significant refactoring and improvements to permission handling for banned users, as well as major UI simplifications and code deduplication in the dispatch and pilot applications. The most important changes are grouped below by backend logic and frontend/UI improvements. **Backend: Permission Handling and Helper Refactoring** - Improved logic for removing and restoring Discord roles for users with penalties, now tracking which permissions have been applied and restoring roles when bans expire or are suspended. Also, the function is now called on a schedule and at startup. [[1]](diffhunk://#diff-073c0556904e6151205e79d30c458fc6efb342019cfae895a8f7a1ec2d0fe98bL144-R168) [[2]](diffhunk://#diff-073c0556904e6151205e79d30c458fc6efb342019cfae895a8f7a1ec2d0fe98bL170-L179) [[3]](diffhunk://#diff-073c0556904e6151205e79d30c458fc6efb342019cfae895a8f7a1ec2d0fe98bR197-R219) - Refactored `setUserStandardNamePermissions` into a reusable helper function, and updated its usage in both route handlers and the backend penalty logic. [[1]](diffhunk://#diff-904d298e2b216db5c5956097474a757c18a7c8d3ada8cfbf8f12a2e1f00ab24aL10-R28) [[2]](diffhunk://#diff-904d298e2b216db5c5956097474a757c18a7c8d3ada8cfbf8f12a2e1f00ab24aR79-R85) - Improved member fetching logic to ensure correct retrieval from cache or Discord API. **Frontend/UI: Navbar and Layout Refactoring** - Consolidated and simplified the Navbar components for both the dispatch and pilot apps, moving shared logic to a single `Navbar` component and passing children for custom controls, reducing code duplication. [[1]](diffhunk://#diff-808c2aeb684705e0b06e64941d25a1cc52c38e87a7dff31fed6e30cc3ced1fa7R1-R32) [[2]](diffhunk://#diff-8dcea08879f59afd80ebc841ab0a8433fe7c7c8e7f650a654feb0a3f60344316L2-R7) [[3]](diffhunk://#diff-8dcea08879f59afd80ebc841ab0a8433fe7c7c8e7f650a654feb0a3f60344316L29-R36) [[4]](diffhunk://#diff-90228fb5f15454c57fdc1df408dfd7bd5c4435c0ad737dee000e6d8964ff2d0fL2-R7) [[5]](diffhunk://#diff-90228fb5f15454c57fdc1df408dfd7bd5c4435c0ad737dee000e6d8964ff2d0fL29-R36) [[6]](diffhunk://#diff-a3a49edf1ebaea0d13a6d2606d2c3ba3dbcce06e3e2dc255b89ec30a03e84f80L1-L63) [[7]](diffhunk://#diff-45850e7a95411aafb8416c8f56b709034394fb441a8c10e601317afc7a9b6b9eL1-L58) - Updated the Mode Switch Dropdown to support more flexible styling and added a direct link to the HUB. [[1]](diffhunk://#diff-e96831a2c33b4ab35ad79a4d1ccddf58946bac9c31b16981be3ba93aca7cfdefL4-R21) [[2]](diffhunk://#diff-e96831a2c33b4ab35ad79a4d1ccddf58946bac9c31b16981be3ba93aca7cfdefR48-R56) - Removed unused or redundant theme switch components from both dispatch and pilot navbars. - Fixed import paths after moving and renaming the `Connection` component. **Other Improvements** - Set the `HOST` environment variable in Dockerfiles for both the dispatch and hub apps to ensure proper network binding. [[1]](diffhunk://#diff-c9fb70056fe8598493c3d4fd243e18d060af692ba433433ed648899b6c0c13b3R78) [[2]](diffhunk://#diff-6ffb00baac7231b462a1a2f84420f8abdd3b2307523c743a83f790ac89558dd9R69) - Minor UI and query cleanups in the hub application for event and path selection components. [[1]](diffhunk://#diff-2538225716f7f6a21184458971cf83f3c1ede98c054d53edfc89832aaa4901dcL26-L34) [[2]](diffhunk://#diff-2538225716f7f6a21184458971cf83f3c1ede98c054d53edfc89832aaa4901dcL50-R47) [[3]](diffhunk://#diff-c7e53917ae04f97d118afc292b7f7a622120f722e98849c0cbfff3970f4f0805L23-R34) These changes improve maintainability, reliability of permission handling, and consistency across the frontend.
Sign in to join this conversation.