Skip to content

Commit

Permalink
Might as well use the const rather than a magic number!
Browse files Browse the repository at this point in the history
  • Loading branch information
briannesbitt committed Dec 5, 2013
1 parent 2ec31b3 commit cad9164
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Carbon/Carbon.php
Original file line number Diff line number Diff line change
Expand Up @@ -1797,7 +1797,7 @@ public function startOfYear()
*/
public function endOfYear()
{
return $this->month(12)->endOfMonth();
return $this->month(self::MONTHS_PER_YEAR)->endOfMonth();
}

/**
Expand Down Expand Up @@ -2061,7 +2061,7 @@ public function firstOfYear($dayOfWeek = null)
*/
public function lastOfYear($dayOfWeek = null)
{
$this->month(12);
$this->month(self::MONTHS_PER_YEAR);

return $this->lastOfMonth($dayOfWeek);
}
Expand Down

0 comments on commit cad9164

Please sign in to comment.