generated from spatie/package-skeleton-php
-
-
Notifications
You must be signed in to change notification settings - Fork 198
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
948c63a
commit 2900145
Showing
1 changed file
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
<?php | ||
|
||
namespace Spatie\Holidays\Countries; | ||
|
||
use Carbon\CarbonImmutable; | ||
|
||
class Ghana extends Country | ||
{ | ||
|
||
public function countryCode(): string | ||
{ | ||
return 'gh'; | ||
} | ||
|
||
protected function allHolidays(int $year): array | ||
{ | ||
return array_merge([ | ||
'New Year\'s Day' => '01-01', | ||
'Constitution Day' => '01-07', | ||
'Independence Day' => '03-06', | ||
'May Day' => '05-01', | ||
'Founder\'s Day' => '08-04', | ||
'Kwame Nkrumah Memorial Day' => '09-21', | ||
'Christmas Day' => '12-25', | ||
'Boxing Day' => '12-26', | ||
], $this->variableHolidays($year)); | ||
} | ||
|
||
protected function variableHolidays(int $year): array | ||
{ | ||
$easter = CarbonImmutable::createFromTimestamp(easter_date($year)) | ||
->setTimezone('Africa/Accra'); | ||
|
||
return []; | ||
} | ||
} |