File tree 4 files changed +8
-4
lines changed
main/java/com/networknt/schema
draft2019-09/optional/format
4 files changed +8
-4
lines changed Original file line number Diff line number Diff line change 71
71
<version .mockito>2.7.21</version .mockito>
72
72
<version .hamcrest>2.2</version .hamcrest>
73
73
<version .undertow>2.2.14.Final</version .undertow>
74
- <version .itu>1.3.0 </version .itu>
74
+ <version .itu>1.5.1 </version .itu>
75
75
</properties >
76
76
<dependencies >
77
77
<dependency >
Original file line number Diff line number Diff line change @@ -65,7 +65,11 @@ private boolean isLegalDateTime(String string) {
65
65
return tryParse (() -> {
66
66
try {
67
67
ITU .parseDateTime (string );
68
- } catch (LeapSecondException ignored ) {}
68
+ } catch (LeapSecondException ex ) {
69
+ if (!ex .isVerifiedValidLeapYearMonth ()) {
70
+ throw ex ;
71
+ }
72
+ }
69
73
});
70
74
} else {
71
75
throw new IllegalStateException ("Unknown format: " + formatName );
Original file line number Diff line number Diff line change 72
72
},
73
73
{
74
74
"description" : " an invalid date-time string with leap second" ,
75
- "data" : " 1998-10 -31T23:59:60Z" ,
75
+ "data" : " 1997-12 -31T23:59:60Z" ,
76
76
"valid" : false
77
77
}
78
78
]
Original file line number Diff line number Diff line change 72
72
},
73
73
{
74
74
"description" : " an invalid date-time string with leap second" ,
75
- "data" : " 1998-10 -31T23:59:60Z" ,
75
+ "data" : " 1997-12 -31T23:59:60Z" ,
76
76
"valid" : false
77
77
}
78
78
]
You can’t perform that action at this time.
0 commit comments