/** * @return bool */ public function handle() { $this->form->cleanupFields(); if (!$this->form->isSubmitted() || !$this->isValid()) { return false; } $fields = $this->form->getFields(); $newStartDate = Model::getUTCTimestamp($fields['start_date']); $newEndDate = Model::getUTCTimestamp($fields['end_date']); $this->dateRange->update($newStartDate, $newEndDate); return true; }