ClimateGlobalChange / tempestextremes

Extreme weather detection and characterization
84 stars 30 forks source link

calendar attribute with different case results in failure in CalendarTypeFromString #13

Closed zarzycki closed 5 years ago

zarzycki commented 5 years ago

Currently code checks for calendar as case-sensitive lowercase. Calendar attributes attached to time variables such as "Gregorian" or "GREGORIAN" cause unknown calendar type.

Suggest either adding both first char and all char caps as matching "if" options in CalendarTypeFromString or some sort of transformation (ex: transform(strCalendar.begin(), strCalendar.end(), strCalendar.begin(), ::tolower);) prior to check.

Will leave up to lead dev to decide what fits workflow best.

paullric commented 5 years ago

Now fixed in commit f27bef30f37915a44b8bb807b0889944ec6dbe5f