Skip to content

fix: avoid setting thisSemesterStartDate when it is missing#677

Merged
w568w merged 3 commits into
DanXi-Dev:mainfrom
sseu-buhzzi:20260510/fix-missing-sem-start-date
May 14, 2026
Merged

fix: avoid setting thisSemesterStartDate when it is missing#677
w568w merged 3 commits into
DanXi-Dev:mainfrom
sseu-buhzzi:20260510/fix-missing-sem-start-date

Conversation

@sseu-buhzzi
Copy link
Copy Markdown
Contributor

For example this semester [1] does not have a start date specified in
the fetched data [2].

[1]

                  <option name="semesterAssoc" value="528">2025-2026学年暑期</option>

[2]

  var semesters = JSON.parse([
    {"startDate":"2026-03-01","endDate":"2026-07-04","name":"2025-2026学年2学期","id":505},
    {"startDate":"2025-09-07","endDate":"2026-01-10","name":"2025-2026学年1学期","id":504},
    {"startDate":"2025-06-22","endDate":"2025-09-06","name":"2024-2025学年暑期","id":506},
    {"startDate":"2025-02-16","endDate":"2025-06-21","name":"2024-2025学年2学期","id":469},
    {"startDate":"2024-09-01","endDate":"2025-01-04","name":"2024-2025学年1学期","id":467},
    {"startDate":"2024-02-25","endDate":"2024-06-29","name":"2023-2024学年2学期","id":464},
    {"startDate":"2023-09-03","endDate":"2024-01-06","name":"2023-2024学年1学期","id":444},
    {"startDate":"2023-02-19","endDate":"2023-06-24","name":"2022-2023学年2学期","id":425},
    {"startDate":"2022-09-04","endDate":"2023-01-07","name":"2022-2023学年1学期","id":404}
  ]);

Copy link
Copy Markdown
Member

@w568w w568w left a comment

Choose a reason for hiding this comment

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

Mostly LGTM. Just a minor change.

Comment thread lib/provider/settings_provider.dart Outdated
@sseu-buhzzi sseu-buhzzi requested a review from w568w May 14, 2026 08:22
Copy link
Copy Markdown
Member

@w568w w568w left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks for your contribution!

@w568w w568w added this to the 1.5.2 milestone May 14, 2026
@w568w w568w added bug Something isn't working internal The request is from our team and not widely applicable. labels May 14, 2026
@w568w w568w merged commit ca30546 into DanXi-Dev:main May 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working internal The request is from our team and not widely applicable.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants