Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed 24-hour format not working for sunrise/sunset #137

Merged
merged 1 commit into from
Jun 15, 2024
Merged

fixed 24-hour format not working for sunrise/sunset #137

merged 1 commit into from
Jun 15, 2024

Conversation

rainloreley
Copy link
Contributor

Fixes #136

It might be better to have a function which only converts any date/timestamp to the correct format selected by the user in the future. The code snippet I added can be found at multiple places within the source code (in different files), which makes it harder to change and maintain if something is changed (e.g. the settings class). Having it in just one function and then calling that with the date/timestamp as an input makes it easier and less prone to bugs like this.

@amit9838
Copy link
Owner

Fixes #136

It might be better to have a function which only converts any date/timestamp to the correct format selected by the user in the future. The code snippet I added can be found at multiple places within the source code (in different files), which makes it harder to change and maintain if something is changed (e.g. the settings class). Having it in just one function and then calling that with the date/timestamp as an input makes it easier and less prone to bugs like this.

Right, I'll do that , thanks

@amit9838 amit9838 merged commit 96217e0 into amit9838:master Jun 15, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: Sunrise/Sunset shows incorrect time in 24-hours
2 participants