public static function updateTerm($appointmentId, $tutorId, $user, $startDate, $endDate, $newTermId, $oldTermId) { if (strcmp($newTermId, $oldTermId) === 0) { return false; } Term::validateId($newTermId); date_default_timezone_set('Europe/Athens'); $startDate = Dates::initDateTime($startDate); $endDate = Dates::initDateTime($endDate); self::validateNewDates($user, $newTermId, $tutorId, $startDate, $endDate, $appointmentId); return AppointmentFetcher::updateTerm($appointmentId, $newTermId); }