You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Setting a Max year below the default YearRange "1950:2055" will cause a crash if the no value has been set to Min.
The method UpdateYearsAndMonths is called from SetParametersAsync before any new YearRange has been applied. Since the YearMin will be set to the default 1950 since no Min has been set, YearMax will be less than YearMin causing a crash.
To Reproduce
Set Max to "1948-01-01" with the Min parameter not set (=null).
Solution
The simplest solution is to set a flag if Max or Min has changed in method SetParametersAsync and call UpdateYearsAndMonths after all parameters has been updated.
Also verify that YearFrom < YearTo to avoid crashes for bad input parameters.