diff --git a/php/libraries/Candidate.class.inc b/php/libraries/Candidate.class.inc index 6d378a483fc..2b4d76d6711 100644 --- a/php/libraries/Candidate.class.inc +++ b/php/libraries/Candidate.class.inc @@ -713,7 +713,7 @@ class Candidate implements \LORIS\StudyEntities\AccessibleResource * * @return int The candidate's age today as years */ - public function getAgeYears(): int + public function getAgeInYears(): int { return (int)$this->getAge()->format('%y'); } @@ -726,7 +726,7 @@ class Candidate implements \LORIS\StudyEntities\AccessibleResource public function getAgeInMonths(): int { return (int)$this->getAge()->format('%m') + - 12 * $this->getAgeYears(); + 12 * $this->getAgeInYears(); } /**