Fix sunrise/sunset date off-by-one
This commit is contained in:
parent
c6f5e373da
commit
4ab15ab61a
1 changed files with 1 additions and 1 deletions
|
|
@ -29,7 +29,7 @@ pub async fn post(server: State<Server>, Form(form): Form<FormData>) -> somehow:
|
|||
|
||||
let first = civil::Date::new(year, month, 1)?;
|
||||
let mut times = vec![];
|
||||
for day in 1..=first.days_in_month() {
|
||||
for day in 0..first.days_in_month() {
|
||||
let date = first + day.days();
|
||||
let (rise, set) = sunrise::sunrise_sunset(
|
||||
form.latitude,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue