Update datepicker.js

Setting date to minDate or maxDate needs to be done by changing the object itself, not its reference.