@@ -75,7 +75,7 @@ |
||
75 | 75 | /** |
76 | 76 | * Get the first media file that contains an image. |
77 | 77 | */ |
78 | - public function firstImageFile(): MediaFile|null |
|
78 | + public function firstImageFile(): MediaFile | null |
|
79 | 79 | { |
80 | 80 | return $this->mediaFiles() |
81 | 81 | ->first(static fn (MediaFile $media_file): bool => $media_file->isImage() && !$media_file->isExternal()); |
@@ -97,7 +97,7 @@ |
||
97 | 97 | { |
98 | 98 | return $individual->spouseFamilies() |
99 | 99 | // Exclude families that were created after this census date |
100 | - ->filter(fn (Family $family): bool => Date::compare($family->getMarriageDate(), $this->date()) <= 0) |
|
100 | + ->filter(fn (Family $family) : bool => Date::compare($family->getMarriageDate(), $this->date()) <= 0) |
|
101 | 101 | ->sort(Family::marriageDateComparator()) |
102 | 102 | ->last(); |
103 | 103 | } |
@@ -1069,7 +1069,7 @@ |
||
1069 | 1069 | * @param Expression|string $column |
1070 | 1070 | * @param array<string> $search_terms |
1071 | 1071 | */ |
1072 | - private function whereSearch(Builder $query, Expression|string $column, array $search_terms): void |
|
1072 | + private function whereSearch(Builder $query, Expression | string $column, array $search_terms): void |
|
1073 | 1073 | { |
1074 | 1074 | foreach ($search_terms as $search_term) { |
1075 | 1075 | $query->where($column, DB::iLike(), '%' . addcslashes($search_term, '\\%_') . '%'); |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | return self::pdo()->getAttribute(PDO::ATTR_DRIVER_NAME); |
141 | 141 | } |
142 | 142 | |
143 | - public static function exec(string $sql): int|false |
|
143 | + public static function exec(string $sql): int | false |
|
144 | 144 | { |
145 | 145 | return self::pdo()->exec($sql); |
146 | 146 | } |
@@ -205,7 +205,7 @@ discard block |
||
205 | 205 | } |
206 | 206 | } |
207 | 207 | |
208 | - public static function binaryColumn(string $column, string|null $alias = null): Expression |
|
208 | + public static function binaryColumn(string $column, string | null $alias = null): Expression |
|
209 | 209 | { |
210 | 210 | if (self::driverName() === self::MYSQL) { |
211 | 211 | $sql = 'CAST(' . $column . ' AS binary)'; |
@@ -35,9 +35,9 @@ discard block |
||
35 | 35 | private readonly bool $unsigned = false, |
36 | 36 | private readonly bool $fixed = false, |
37 | 37 | private readonly bool $nullable = false, |
38 | - private readonly float|int|string|null $default = null, |
|
38 | + private readonly float | int | string | null $default = null, |
|
39 | 39 | private readonly bool $autoincrement = false, |
40 | - private readonly string|null $collation = null, |
|
40 | + private readonly string | null $collation = null, |
|
41 | 41 | ) { |
42 | 42 | parent::__construct( |
43 | 43 | name: $name, |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | ); |
74 | 74 | } |
75 | 75 | |
76 | - public function default(float|int|string $default): self |
|
76 | + public function default(float | int | string $default): self |
|
77 | 77 | { |
78 | 78 | return new self( |
79 | 79 | name: $this->name, |
@@ -29,7 +29,7 @@ |
||
29 | 29 | /** |
30 | 30 | * @param array<int,string> $columns |
31 | 31 | */ |
32 | - public function __construct(private readonly array $columns, string|null $name = null) |
|
32 | + public function __construct(private readonly array $columns, string | null $name = null) |
|
33 | 33 | { |
34 | 34 | parent::__construct(name: $name, columns: $this->columns); |
35 | 35 | } |
@@ -32,7 +32,7 @@ |
||
32 | 32 | /** |
33 | 33 | * @param array<int,string> $columns |
34 | 34 | */ |
35 | - public function __construct(private readonly array $columns, string|null $name = null) |
|
35 | + public function __construct(private readonly array $columns, string | null $name = null) |
|
36 | 36 | { |
37 | 37 | parent::__construct(name: $name, columns: $this->columns, isUnique: true); |
38 | 38 | } |
@@ -240,7 +240,7 @@ |
||
240 | 240 | /** |
241 | 241 | * Run the application. |
242 | 242 | */ |
243 | - public function run(string $php_sapi): int|ResponseInterface |
|
243 | + public function run(string $php_sapi): int | ResponseInterface |
|
244 | 244 | { |
245 | 245 | if ($php_sapi === 'cli') { |
246 | 246 | return $this->bootstrap()->cliRequest(); |
@@ -72,11 +72,11 @@ |
||
72 | 72 | $user->realName(), |
73 | 73 | $user->email(), |
74 | 74 | Auth::isAdmin(user: $user) ? 'Yes' : 'No', |
75 | - $user->getPreference(setting_name: UserInterface::PREF_IS_ACCOUNT_APPROVED) ? 'Yes' : 'No', |
|
76 | - $user->getPreference(setting_name: UserInterface::PREF_IS_EMAIL_VERIFIED) ? 'Yes' : 'No', |
|
77 | - $user->getPreference(setting_name: UserInterface::PREF_LANGUAGE), |
|
78 | - $user->getPreference(setting_name: UserInterface::PREF_TIME_ZONE), |
|
79 | - $user->getPreference(setting_name: UserInterface::PREF_CONTACT_METHOD), |
|
75 | + $user->getPreference(setting_name : UserInterface::PREF_IS_ACCOUNT_APPROVED) ? 'Yes' : 'No', |
|
76 | + $user->getPreference(setting_name : UserInterface::PREF_IS_EMAIL_VERIFIED) ? 'Yes' : 'No', |
|
77 | + $user->getPreference(setting_name : UserInterface::PREF_LANGUAGE), |
|
78 | + $user->getPreference(setting_name : UserInterface::PREF_TIME_ZONE), |
|
79 | + $user->getPreference(setting_name : UserInterface::PREF_CONTACT_METHOD), |
|
80 | 80 | $registered, |
81 | 81 | $last_login, |
82 | 82 | ]); |