prayer-times
prayer-times copied to clipboard
NightPortion method returns 0 for angle based rule calculations
Asalamu alaikum wa rahmatullahi wa barakatu akhi,
The line : if (this.HighLatitudeAdjustmentMethod == HighLatitudeAdjustmentMethods.AngleBased) return 1 / 60 * angle;
Should be : if (this.HighLatitudeAdjustmentMethod == HighLatitudeAdjustmentMethods.AngleBased) return 1d / 60d * angle;
Without this, the fraction returns 0 ( as it does integer division and returns a whole number), by setting the values to doubles a fraction is returned and angle based calculations work correctly.
Jazakallahu khairan for your good work.
Nad