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

Add DST offset config #6

Merged
merged 3 commits into from
Dec 5, 2022
Merged

Add DST offset config #6

merged 3 commits into from
Dec 5, 2022

Conversation

OJ7
Copy link
Contributor

@OJ7 OJ7 commented Dec 3, 2022

Added a DST offset config which allows offsetting prayer times by -1, 0, or +1 hours. This allows adjusting in case there are errors in the prayer calculation library (see #4).

Originally, I hardcoded the adjustment, but realized the offset may not always be required/vary by location.

General Config Page:
image

DST Config Page:
image

@OJ7 OJ7 changed the title fix: workaround for DST bug in Azan library Add DST offset config Dec 4, 2022
Copy link
Owner

@tazzix tazzix left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you

@tazzix tazzix merged commit 1151da0 into tazzix:main Dec 5, 2022
@@ -46,6 +52,7 @@ fun Context.getAddressDescription(location: MyLocation, resolveLocality: Boolean
if (locationVal.isEmpty()) locationVal = String.format("%.3f, %.3f", location.latitude, location.longitude)

val today = SimpleDate(GregorianCalendar())
// Subtract 1 from DST due to bug in library: https://github.com/ahmedeltaher/Prayer-Times-Android-Azan/issues/27#issue-866377567
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whoops, forgot to delete this line. I'll likely be pushing some more changes and can remove in another PR.

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.

2 participants