Skip to content

Conversation

@Dalia-Alawneh
Copy link

No description provided.

In this commit, I refactored the app.loadConfig() function to improve the handling of configurations. The changes include:

1. Extracted loadNewConfig(), setDefaultValues(), checkConfigChanges(), and checkPortChanges() functions for better code organization and reusability.
2. Set default values for siteName, enableChangelogs, and boardSize if not specified in the configuration.
3. Ensured colors are stored as uppercase unique values in app.colours.
4. Improved the conditional checks for changes in the configuration, database, board size, OAuth settings, and port number.
5. Restructured the code to handle different scenarios more efficiently.

These refactorings enhance the readability, maintainability, and overall quality of the codebase. The core functionality of app.loadConfig() remains intact, but the code is now more organized and easier to understand.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant