fixed -
self.options.lastDate should not be updated if date is undefined.