Skip to content

Commit c731210

Browse files
Accept local date times without seconds
1 parent bc17090 commit c731210

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

core/shared/src/main/scala/plotly/element/LocalDateTime.scala

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ object LocalDateTime extends PlotlyJavaTimeConversions {
3030
(d.split('-'), t.split(':')) match {
3131
case (Array(IntStr(y), IntStr(m), IntStr(d)), Array(IntStr(h), IntStr(min), IntStr(s))) =>
3232
Some(LocalDateTime(y, m, d, h, min, s))
33+
case (Array(IntStr(y), IntStr(m), IntStr(d)), Array(IntStr(h), IntStr(min))) =>
34+
Some(LocalDateTime(y, m, d, h, min, 0))
3335
case _ => None
3436
}
3537
case _ => None

0 commit comments

Comments
 (0)