File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -180,7 +180,7 @@ $.extend(Timepicker.prototype, {
180180 // parse the time string from input value or _setTime
181181 //########################################################################
182182 _parseTime : function ( timeString , withDate ) {
183- var regstr = this . _defaults . separator + this . _defaults . timeFormat . toString ( )
183+ var regstr = this . _defaults . timeFormat . toString ( )
184184 . replace ( / h { 1 , 2 } / ig, '(\\d?\\d)' )
185185 . replace ( / m { 1 , 2 } / ig, '(\\d?\\d)' )
186186 . replace ( / s { 1 , 2 } / ig, '(\\d?\\d)' )
@@ -195,7 +195,7 @@ $.extend(Timepicker.prototype, {
195195 // the time should come after x number of characters and a space.
196196 // x = at least the length of text specified by the date format
197197 var dp_dateFormat = $ . datepicker . _get ( this . inst , 'dateFormat' ) ;
198- regstr = '.{' + dp_dateFormat . length + ',}\\s*' + regstr ;
198+ regstr = '.{' + dp_dateFormat . length + ',}\\s*' + this . _defaults . separator . replace ( / \s / g , '\\s?' ) + regstr ;
199199 }
200200
201201 treg = timeString . match ( new RegExp ( regstr , 'i' ) ) ;
You can’t perform that action at this time.
0 commit comments