Fallback to system time zone on calendar creation with an invalid one.
ClosedPublic

Authored by dcaliste on Nov 18 2019, 12:42 PM.

Details

Summary

ensure to always have a valid time zone defined
for a calendar. Fallback to the system time zone if
provided time zone object or ID is invalid.

Test Plan

add a test in memory calendar to verify
that creating a calendar with an invalid time zone
results in the system one being used.

Diff Detail

Repository
R172 KCalendar Core
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
dcaliste created this revision.Nov 18 2019, 12:42 PM
Restricted Application added a project: KDE PIM. · View Herald TranscriptNov 18 2019, 12:42 PM
Restricted Application added a subscriber: kde-pim. · View Herald Transcript
dcaliste requested review of this revision.Nov 18 2019, 12:42 PM

Here is the patch to ensure that a calendar cannot be created with an invalid time zone.

vkrause accepted this revision.Nov 18 2019, 1:00 PM

Thanks for taking care of this!

This revision is now accepted and ready to land.Nov 18 2019, 1:00 PM
This revision was automatically updated to reflect the committed changes.

Thanks for the review and having found the issue. Commited.