Commits

Robert Tolliver committed f4e6780 Draft

fix match indexes.

Comments (0)

Files changed (1)

djutils/features/fuzzydate/forms.py

 		else:
 			m = m.groups()
 			if precision == DatePrecision.decade:
-				date = datetime.date(year=m[3] or (m[1]*10),
+				date = datetime.date(year=m[2] or (m[0]*10),
 									month=1, day=1)
 			elif precision == DatePrecision.century:
-				date = datetime.date(year=m[3] or (m[1]*100),
+				date = datetime.date(year=m[2] or (m[0]*100),
 				month=1, day=1)
 			else:
 				date = datetime.date(int(m[0]), (int(m[1])-1)*month_factor+1, 1)