@@ -45,10 +45,10 @@ discard block |
||
45 | 45 | /** |
46 | 46 | * Find the user with a specified user_id. |
47 | 47 | */ |
48 | - public function find(int|null $user_id): User|null |
|
48 | + public function find(int | null $user_id): User | null |
|
49 | 49 | { |
50 | 50 | return Registry::cache()->array() |
51 | - ->remember('user-' . $user_id, static fn(): User|null => DB::table('user') |
|
51 | + ->remember('user-' . $user_id, static fn(): User | null => DB::table('user') |
|
52 | 52 | ->where('user_id', '=', $user_id) |
53 | 53 | ->get() |
54 | 54 | ->map(User::rowMapper()) |
@@ -58,7 +58,7 @@ discard block |
||
58 | 58 | /** |
59 | 59 | * Find the user with a specified email address. |
60 | 60 | */ |
61 | - public function findByEmail(string $email): User|null |
|
61 | + public function findByEmail(string $email): User | null |
|
62 | 62 | { |
63 | 63 | return DB::table('user') |
64 | 64 | ->where('email', '=', $email) |
@@ -70,7 +70,7 @@ discard block |
||
70 | 70 | /** |
71 | 71 | * Find the user with a specified user_name or email address. |
72 | 72 | */ |
73 | - public function findByIdentifier(string $identifier): User|null |
|
73 | + public function findByIdentifier(string $identifier): User | null |
|
74 | 74 | { |
75 | 75 | return DB::table('user') |
76 | 76 | ->where('user_name', '=', $identifier) |
@@ -102,7 +102,7 @@ discard block |
||
102 | 102 | /** |
103 | 103 | * Find the user with a specified password reset token. |
104 | 104 | */ |
105 | - public function findByToken(string $token): User|null |
|
105 | + public function findByToken(string $token): User | null |
|
106 | 106 | { |
107 | 107 | return DB::table('user') |
108 | 108 | ->join('user_setting AS us1', 'us1.user_id', '=', 'user.user_id') |
@@ -120,7 +120,7 @@ discard block |
||
120 | 120 | /** |
121 | 121 | * Find the user with a specified user_name. |
122 | 122 | */ |
123 | - public function findByUserName(string $user_name): User|null |
|
123 | + public function findByUserName(string $user_name): User | null |
|
124 | 124 | { |
125 | 125 | return DB::table('user') |
126 | 126 | ->where('user_name', '=', $user_name) |
@@ -209,7 +209,7 @@ discard block |
||
209 | 209 | |
210 | 210 | private static Translator $translator; |
211 | 211 | |
212 | - private static Collator|null $collator = null; |
|
212 | + private static Collator | null $collator = null; |
|
213 | 213 | |
214 | 214 | /** |
215 | 215 | * The preferred locales for this site, or a default list if no preference. |
@@ -248,7 +248,7 @@ discard block |
||
248 | 248 | * |
249 | 249 | * @return string |
250 | 250 | */ |
251 | - public static function digits(string|int $n): string |
|
251 | + public static function digits(string | int $n): string |
|
252 | 252 | { |
253 | 253 | return self::$locale->digits((string) $n); |
254 | 254 | } |
@@ -316,7 +316,7 @@ discard block |
||
316 | 316 | * @return string |
317 | 317 | */ |
318 | 318 | public function chartIndisWithSources( |
319 | - string|null $color_from = null, |
|
319 | + string | null $color_from = null, |
|
320 | 320 | string $color_to = null |
321 | 321 | ): string { |
322 | 322 | return $this->individual_repository->chartIndisWithSources($color_from, $color_to); |
@@ -369,7 +369,7 @@ discard block |
||
369 | 369 | * @return string |
370 | 370 | */ |
371 | 371 | public function chartFamsWithSources( |
372 | - string|null $color_from = null, |
|
372 | + string | null $color_from = null, |
|
373 | 373 | string $color_to = null |
374 | 374 | ): string { |
375 | 375 | return $this->individual_repository->chartFamsWithSources($color_from, $color_to); |
@@ -581,8 +581,8 @@ discard block |
||
581 | 581 | * @return string |
582 | 582 | */ |
583 | 583 | public function chartSex( |
584 | - string|null $color_female = null, |
|
585 | - string|null $color_male = null, |
|
584 | + string | null $color_female = null, |
|
585 | + string | null $color_male = null, |
|
586 | 586 | string $color_unknown = null |
587 | 587 | ): string { |
588 | 588 | return $this->individual_repository->chartSex($color_female, $color_male, $color_unknown); |
@@ -626,7 +626,7 @@ discard block |
||
626 | 626 | * |
627 | 627 | * @return string |
628 | 628 | */ |
629 | - public function chartMortality(string|null $color_living = null, string|null $color_dead = null): string |
|
629 | + public function chartMortality(string | null $color_living = null, string | null $color_dead = null): string |
|
630 | 630 | { |
631 | 631 | return $this->individual_repository->chartMortality($color_living, $color_dead); |
632 | 632 | } |
@@ -797,7 +797,7 @@ discard block |
||
797 | 797 | * |
798 | 798 | * @return string |
799 | 799 | */ |
800 | - public function chartMedia(string|null $color_from = null, string|null $color_to = null): string |
|
800 | + public function chartMedia(string | null $color_from = null, string | null $color_to = null): string |
|
801 | 801 | { |
802 | 802 | return $this->media_repository->chartMedia($color_from, $color_to); |
803 | 803 | } |
@@ -949,7 +949,7 @@ discard block |
||
949 | 949 | * |
950 | 950 | * @return string |
951 | 951 | */ |
952 | - public function statsBirth(string|null $color_from = null, string|null $color_to = null): string |
|
952 | + public function statsBirth(string | null $color_from = null, string | null $color_to = null): string |
|
953 | 953 | { |
954 | 954 | return $this->individual_repository->statsBirth($color_from, $color_to); |
955 | 955 | } |
@@ -1046,7 +1046,7 @@ discard block |
||
1046 | 1046 | * |
1047 | 1047 | * @return string |
1048 | 1048 | */ |
1049 | - public function statsDeath(string|null $color_from = null, string|null $color_to = null): string |
|
1049 | + public function statsDeath(string | null $color_from = null, string | null $color_to = null): string |
|
1050 | 1050 | { |
1051 | 1051 | return $this->individual_repository->statsDeath($color_from, $color_to); |
1052 | 1052 | } |
@@ -1468,7 +1468,7 @@ discard block |
||
1468 | 1468 | * |
1469 | 1469 | * @return string |
1470 | 1470 | */ |
1471 | - public function statsMarr(string|null $color_from = null, string|null $color_to = null): string |
|
1471 | + public function statsMarr(string | null $color_from = null, string | null $color_to = null): string |
|
1472 | 1472 | { |
1473 | 1473 | return $this->family_repository->statsMarr($color_from, $color_to); |
1474 | 1474 | } |
@@ -1543,7 +1543,7 @@ discard block |
||
1543 | 1543 | * |
1544 | 1544 | * @return string |
1545 | 1545 | */ |
1546 | - public function statsDiv(string|null $color_from = null, string|null $color_to = null): string |
|
1546 | + public function statsDiv(string | null $color_from = null, string | null $color_to = null): string |
|
1547 | 1547 | { |
1548 | 1548 | return $this->family_repository->statsDiv($color_from, $color_to); |
1549 | 1549 | } |
@@ -1978,8 +1978,8 @@ discard block |
||
1978 | 1978 | * @return string |
1979 | 1979 | */ |
1980 | 1980 | public function chartLargestFamilies( |
1981 | - string|null $color_from = null, |
|
1982 | - string|null $color_to = null, |
|
1981 | + string | null $color_from = null, |
|
1982 | + string | null $color_to = null, |
|
1983 | 1983 | string $total = '10' |
1984 | 1984 | ): string { |
1985 | 1985 | return $this->family_repository->chartLargestFamilies($color_from, $color_to, (int) $total); |
@@ -2189,8 +2189,8 @@ discard block |
||
2189 | 2189 | * @return string |
2190 | 2190 | */ |
2191 | 2191 | public function chartCommonSurnames( |
2192 | - string|null $color_from = null, |
|
2193 | - string|null $color_to = null, |
|
2192 | + string | null $color_from = null, |
|
2193 | + string | null $color_to = null, |
|
2194 | 2194 | string $number_of_surnames = '10' |
2195 | 2195 | ): string { |
2196 | 2196 | return $this->individual_repository |
@@ -2425,8 +2425,8 @@ discard block |
||
2425 | 2425 | * @return string |
2426 | 2426 | */ |
2427 | 2427 | public function chartCommonGiven( |
2428 | - string|null $color_from = null, |
|
2429 | - string|null $color_to = null, |
|
2428 | + string | null $color_from = null, |
|
2429 | + string | null $color_to = null, |
|
2430 | 2430 | string $maxtoshow = '7' |
2431 | 2431 | ): string { |
2432 | 2432 | return $this->individual_repository->chartCommonGiven($color_from, $color_to, (int) $maxtoshow); |
@@ -2551,7 +2551,7 @@ discard block |
||
2551 | 2551 | * |
2552 | 2552 | * @return string |
2553 | 2553 | */ |
2554 | - public function latestUserRegDate(string|null $format = null): string |
|
2554 | + public function latestUserRegDate(string | null $format = null): string |
|
2555 | 2555 | { |
2556 | 2556 | return $this->latest_user_repository->latestUserRegDate($format); |
2557 | 2557 | } |
@@ -2561,7 +2561,7 @@ discard block |
||
2561 | 2561 | * |
2562 | 2562 | * @return string |
2563 | 2563 | */ |
2564 | - public function latestUserRegTime(string|null $format = null): string |
|
2564 | + public function latestUserRegTime(string | null $format = null): string |
|
2565 | 2565 | { |
2566 | 2566 | return $this->latest_user_repository->latestUserRegTime($format); |
2567 | 2567 | } |
@@ -2572,7 +2572,7 @@ discard block |
||
2572 | 2572 | * |
2573 | 2573 | * @return string |
2574 | 2574 | */ |
2575 | - public function latestUserLoggedin(string|null $yes = null, string|null $no = null): string |
|
2575 | + public function latestUserLoggedin(string | null $yes = null, string | null $no = null): string |
|
2576 | 2576 | { |
2577 | 2577 | return $this->latest_user_repository->latestUserLoggedin($yes, $no); |
2578 | 2578 | } |
@@ -2796,7 +2796,7 @@ discard block |
||
2796 | 2796 | * |
2797 | 2797 | * @return string|null |
2798 | 2798 | */ |
2799 | - public function callBlock(string $block = '', ...$params): string|null |
|
2799 | + public function callBlock(string $block = '', ...$params): string | null |
|
2800 | 2800 | { |
2801 | 2801 | /** @var ModuleBlockInterface|null $module */ |
2802 | 2802 | $module = $this->module_service |
@@ -103,7 +103,7 @@ |
||
103 | 103 | * |
104 | 104 | * @return array<string>|null [nominative, genitive] or null |
105 | 105 | */ |
106 | - public function match(array $nodes, array $patterns): array|null |
|
106 | + public function match(array $nodes, array $patterns): array | null |
|
107 | 107 | { |
108 | 108 | $captures = []; |
109 | 109 |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | /** |
32 | 32 | * Create a note. |
33 | 33 | */ |
34 | - public function make(string $xref, Tree $tree, string|null $gedcom = null): Note|null; |
|
34 | + public function make(string $xref, Tree $tree, string | null $gedcom = null): Note | null; |
|
35 | 35 | |
36 | 36 | /** |
37 | 37 | * Create a note from a row in the database. |
@@ -53,5 +53,5 @@ discard block |
||
53 | 53 | * |
54 | 54 | * @return Note |
55 | 55 | */ |
56 | - public function new(string $xref, string $gedcom, string|null $pending, Tree $tree): Note; |
|
56 | + public function new(string $xref, string $gedcom, string | null $pending, Tree $tree): Note; |
|
57 | 57 | } |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | * |
31 | 31 | * @return TimestampInterface |
32 | 32 | */ |
33 | - public function make(int $timestamp, UserInterface|null $user = null): TimestampInterface; |
|
33 | + public function make(int $timestamp, UserInterface | null $user = null): TimestampInterface; |
|
34 | 34 | |
35 | 35 | /** |
36 | 36 | * @param string|null $string YYYY-MM-DD HH:MM:SS (as provided by SQL). |
@@ -39,12 +39,12 @@ discard block |
||
39 | 39 | * |
40 | 40 | * @return TimestampInterface |
41 | 41 | */ |
42 | - public function fromString(string|null $string, string $format = 'Y-m-d H:i:s', UserInterface|null $user = null): TimestampInterface; |
|
42 | + public function fromString(string | null $string, string $format = 'Y-m-d H:i:s', UserInterface | null $user = null): TimestampInterface; |
|
43 | 43 | |
44 | 44 | /** |
45 | 45 | * @param UserInterface|null $user |
46 | 46 | * |
47 | 47 | * @return TimestampInterface |
48 | 48 | */ |
49 | - public function now(UserInterface|null $user = null): TimestampInterface; |
|
49 | + public function now(UserInterface | null $user = null): TimestampInterface; |
|
50 | 50 | } |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | /** |
32 | 32 | * Create a GedcomRecord object. |
33 | 33 | */ |
34 | - public function make(string $xref, Tree $tree, string|null $gedcom = null): GedcomRecord|null; |
|
34 | + public function make(string $xref, Tree $tree, string | null $gedcom = null): GedcomRecord | null; |
|
35 | 35 | |
36 | 36 | /** |
37 | 37 | * Create a GedcomRecord object from raw GEDCOM data. |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | * |
45 | 45 | * @return GedcomRecord |
46 | 46 | */ |
47 | - public function new(string $xref, string $gedcom, string|null $pending, Tree $tree): GedcomRecord; |
|
47 | + public function new(string $xref, string $gedcom, string | null $pending, Tree $tree): GedcomRecord; |
|
48 | 48 | |
49 | 49 | /** |
50 | 50 | * Create a GedcomRecord object from a row in the database. |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | /** |
32 | 32 | * Create a family. |
33 | 33 | */ |
34 | - public function make(string $xref, Tree $tree, string|null $gedcom = null): Family|null; |
|
34 | + public function make(string $xref, Tree $tree, string | null $gedcom = null): Family | null; |
|
35 | 35 | |
36 | 36 | /** |
37 | 37 | * Create a Family object from a row in the database. |
@@ -53,5 +53,5 @@ discard block |
||
53 | 53 | * |
54 | 54 | * @return Family |
55 | 55 | */ |
56 | - public function new(string $xref, string $gedcom, string|null $pending, Tree $tree): Family; |
|
56 | + public function new(string $xref, string $gedcom, string | null $pending, Tree $tree): Family; |
|
57 | 57 | } |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | /** |
32 | 32 | * Create a submission. |
33 | 33 | */ |
34 | - public function make(string $xref, Tree $tree, string|null $gedcom = null): Submission|null; |
|
34 | + public function make(string $xref, Tree $tree, string | null $gedcom = null): Submission | null; |
|
35 | 35 | |
36 | 36 | /** |
37 | 37 | * Create a submission from a row in the database. |
@@ -53,5 +53,5 @@ discard block |
||
53 | 53 | * |
54 | 54 | * @return Submission |
55 | 55 | */ |
56 | - public function new(string $xref, string $gedcom, string|null $pending, Tree $tree): Submission; |
|
56 | + public function new(string $xref, string $gedcom, string | null $pending, Tree $tree): Submission; |
|
57 | 57 | } |