Skip to content

Commit

Permalink
Namespace constants
Browse files Browse the repository at this point in the history
  • Loading branch information
shaedrich authored Dec 19, 2024
1 parent a1d1d48 commit 37be0fd
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/Illuminate/Support/Date/constants.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,22 @@

namespace Illuminate\Support\Date;

if (! defined('SECONDS_PER_MINUTE')) {
define('SECONDS_PER_MINUTE', 60);
if (! defined(__NAMESPACE__.'\\'.($constant = 'SECONDS_PER_MINUTE'))) {
define(__NAMESPACE__.'\\'.$constant, 60);
}

if (! defined('MINUTES_PER_HOUR')) {
define('MINUTES_PER_HOUR', 60);
if (! defined(__NAMESPACE__.'\\'.($constant = 'MINUTES_PER_HOUR'))) {
define(__NAMESPACE__.'\\'.$constant, 60);
}

if (! defined('HOURS_PER_DAY')) {
define('HOURS_PER_DAY', 24);
if (! defined(__NAMESPACE__.'\\'.($constant = 'HOURS_PER_DAY'))) {
define(__NAMESPACE__.'\\'.$constant, 24);
}

if (! defined('DAYS_PER_WEEK')) {
define('DAYS_PER_WEEK', 7);
if (! defined(__NAMESPACE__.'\\'.($constant = 'DAYS_PER_WEEK'))) {
define(__NAMESPACE__.'\\'.$constant, 7);
}

if (! defined('MONTHS_PER_YEAR')) {
define('MONTHS_PER_YEAR', 12);
if (! defined(__NAMESPACE__.'\\'.($constant = 'MONTHS_PER_YEAR'))) {
define(__NAMESPACE__.'\\'.$constant, 12);
}

0 comments on commit 37be0fd

Please sign in to comment.