You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It can happen that after a non-inline Datepicker is opened, the <input> which the datepicker is "attached to" is removed from the DOM. When the user then clicks on the Datepicker calendar, an exception will be thrown with the message: "Missing instance data for this datepicker".
This is the relevant bit of code:
/* Adjust one of the date sub-fields. */
_adjustDate: function( id, offset, period ) {
var target = $( id ),
inst = this._getInst( target[ 0 ] );
Note that after retrieving target with $( id ), it is used right away without checking whether target.length > 0 or not. I would like to suggest it would be a good idea to make that check. If target is indeed empty, then an exception could be thrown with a more informative message.
(A web search reveals a lot of questions about the Missing instance data message; apparently it is challenging for a lot of users to understand what this message indicates.)
The text was updated successfully, but these errors were encountered:
It can happen that after a non-inline Datepicker is opened, the
<input>
which the datepicker is "attached to" is removed from the DOM. When the user then clicks on the Datepicker calendar, an exception will be thrown with the message:"Missing instance data for this datepicker"
.This is the relevant bit of code:
Note that after retrieving
target
with$( id )
, it is used right away without checking whethertarget.length > 0
or not. I would like to suggest it would be a good idea to make that check. Iftarget
is indeed empty, then an exception could be thrown with a more informative message.(A web search reveals a lot of questions about the
Missing instance data
message; apparently it is challenging for a lot of users to understand what this message indicates.)The text was updated successfully, but these errors were encountered: