Skip to content

Commit

Permalink
fix php8.1 requirement
Browse files Browse the repository at this point in the history
  • Loading branch information
ildyria committed Apr 15, 2023
1 parent cacfc7b commit adabfcd
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions app/Factories/AlbumFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,21 @@

class AlbumFactory
{
// PHP 8.2
// public const BUILTIN_SMARTS_CLASS = [
// SmartAlbumType::UNSORTED->value => UnsortedAlbum::class,
// SmartAlbumType::STARRED->value => StarredAlbum::class,
// SmartAlbumType::PUBLIC->value => PublicAlbum::class,
// SmartAlbumType::RECENT->value => RecentAlbum::class,
// SmartAlbumType::ON_THIS_DAY->value => OnThisDayAlbum::class,
// ];

public const BUILTIN_SMARTS_CLASS = [
SmartAlbumType::UNSORTED->value => UnsortedAlbum::class,
SmartAlbumType::STARRED->value => StarredAlbum::class,
SmartAlbumType::PUBLIC->value => PublicAlbum::class,
SmartAlbumType::RECENT->value => RecentAlbum::class,
SmartAlbumType::ON_THIS_DAY->value => OnThisDayAlbum::class,
'unsorted' => UnsortedAlbum::class,
'starred' => StarredAlbum::class,
'public' => PublicAlbum::class,
'recent' => RecentAlbum::class,
'on_this_day' => OnThisDayAlbum::class,
];

/**
Expand Down

0 comments on commit adabfcd

Please sign in to comment.