Passed
Push — develop ( df1f3f...87a4e2 )
by Greg
11:15
created
app/Module/ShareAnniversaryModule.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
     {
101 101
         if ($record instanceof Individual) {
102 102
             $facts = $record->facts(static::INDIVIDUAL_EVENTS, true)
103
-                ->merge($record->spouseFamilies()->map(fn (Family $family): Collection => $family->facts(static::FAMILY_EVENTS, true)));
103
+                ->merge($record->spouseFamilies()->map(fn(Family $family): Collection => $family->facts(static::FAMILY_EVENTS, true)));
104 104
         } elseif ($record instanceof Family) {
105 105
             $facts = $record->facts(static::FAMILY_EVENTS, true);
106 106
         } else {
@@ -110,11 +110,11 @@  discard block
 block discarded – undo
110 110
         // iCalendar only supports exact Gregorian dates.
111 111
         $facts = $facts
112 112
             ->flatten()
113
-            ->filter(fn (Fact $fact): bool => $fact->date()->isOK())
114
-            ->filter(fn (Fact $fact): bool => $fact->date()->qual1 === '')
115
-            ->filter(fn (Fact $fact): bool => $fact->date()->minimumDate() instanceof GregorianDate)
116
-            ->filter(fn (Fact $fact): bool => $fact->date()->minimumJulianDay() === $fact->date()->maximumJulianDay())
117
-            ->mapWithKeys(fn (Fact $fact): array => [
113
+            ->filter(fn(Fact $fact): bool => $fact->date()->isOK())
114
+            ->filter(fn(Fact $fact): bool => $fact->date()->qual1 === '')
115
+            ->filter(fn(Fact $fact): bool => $fact->date()->minimumDate() instanceof GregorianDate)
116
+            ->filter(fn(Fact $fact): bool => $fact->date()->minimumJulianDay() === $fact->date()->maximumJulianDay())
117
+            ->mapWithKeys(fn(Fact $fact): array => [
118 118
                 route(static::class, ['tree' => $record->tree()->name(), 'xref' => $fact->record()->xref(), 'fact_id' => $fact->id()]) =>
119 119
                     $fact->label() . ' — ' . $fact->date()->display(),
120 120
             ]);
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
         $record  = Auth::checkRecordAccess($record);
147 147
 
148 148
         $fact = $record->facts()
149
-            ->filter(fn (Fact $fact): bool => $fact->id() === $fact_id)
149
+            ->filter(fn(Fact $fact): bool => $fact->id() === $fact_id)
150 150
             ->first();
151 151
 
152 152
         if ($fact instanceof Fact) {
Please login to merge, or discard this patch.
app/Statistics/Repository/IndividualRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -588,7 +588,7 @@
 block discarded – undo
588 588
 
589 589
         $module = $module_service
590 590
             ->findByComponent(ModuleListInterface::class, $this->tree, Auth::user())
591
-            ->first(static fn (ModuleInterface $module): bool => $module instanceof IndividualListModule);
591
+            ->first(static fn(ModuleInterface $module): bool => $module instanceof IndividualListModule);
592 592
 
593 593
         if ($type === 'list') {
594 594
             return view('lists/surnames-bullet-list', [
Please login to merge, or discard this patch.
app/Module/ModuleThemeTrait.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -397,7 +397,7 @@  discard block
 block discarded – undo
397 397
 
398 398
         $pedigree_chart = $module_service
399 399
             ->findByComponent(ModuleChartInterface::class, $tree, Auth::user())
400
-            ->first(static fn (ModuleInterface $module): bool => $module instanceof PedigreeChartModule);
400
+            ->first(static fn(ModuleInterface $module): bool => $module instanceof PedigreeChartModule);
401 401
 
402 402
         if ($my_xref !== '' && $pedigree_chart instanceof PedigreeChartModule) {
403 403
             $individual = Registry::individualFactory()->make($my_xref, $tree);
@@ -486,7 +486,7 @@  discard block
 block discarded – undo
486 486
 
487 487
         return $module_service
488 488
             ->findByComponent(ModuleMenuInterface::class, $tree, Auth::user())
489
-            ->map(static fn (ModuleMenuInterface $menu): ?Menu => $menu->getMenu($tree))
489
+            ->map(static fn(ModuleMenuInterface $menu): ?Menu => $menu->getMenu($tree))
490 490
             ->filter()
491 491
             ->all();
492 492
     }
Please login to merge, or discard this patch.
app/Module/FamilyTreeStatisticsModule.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -145,7 +145,7 @@
 block discarded – undo
145 145
             // Find a module providing individual lists
146 146
             $module = $this->module_service
147 147
                 ->findByComponent(ModuleListInterface::class, $tree, Auth::user())
148
-                ->first(static fn (ModuleInterface $module): bool => $module instanceof IndividualListModule);
148
+                ->first(static fn(ModuleInterface $module): bool => $module instanceof IndividualListModule);
149 149
 
150 150
             $surnames = view('lists/surnames-compact-list', [
151 151
                 'module'   => $module,
Please login to merge, or discard this patch.
app/Module/RelationshipsChartModule.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -328,7 +328,7 @@
 block discarded – undo
328 328
 
329 329
             $language = $this->module_service
330 330
                 ->findByInterface(ModuleLanguageInterface::class, true)
331
-                ->first(fn (ModuleLanguageInterface $language): bool => $language->locale()->languageTag() === I18N::languageTag());
331
+                ->first(fn(ModuleLanguageInterface $language): bool => $language->locale()->languageTag() === I18N::languageTag());
332 332
 
333 333
             echo '<h3>', I18N::translate('Relationship: %s', $this->relationship_service->nameFromPath($nodes->all(), $language)), '</h3>';
334 334
             $num_paths++;
Please login to merge, or discard this patch.
app/Session.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
         $path   = (string) parse_url($url, PHP_URL_PATH);
70 70
 
71 71
         // Paths containing UTF-8 characters need special handling.
72
-        $path = implode('/', array_map(static fn (string $x): string => rawurlencode($x), explode('/', $path)));
72
+        $path = implode('/', array_map(static fn(string $x): string => rawurlencode($x), explode('/', $path)));
73 73
 
74 74
         session_name($secure ? self::SECURE_SESSION_NAME : self::SESSION_NAME);
75 75
         session_register_shutdown();
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
      *
110 110
      * @return array|bool|int|null|string
111 111
      */
112
-    public static function get(string $name, array|bool|int|string $default = null)
112
+    public static function get(string $name, array | bool | int | string $default = null)
113 113
     {
114 114
         return $_SESSION[$name] ?? $default;
115 115
     }
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
      *
122 122
      * @return array|bool|int|null|string
123 123
      */
124
-    public static function pull(string $name): array|bool|int|null|string
124
+    public static function pull(string $name): array | bool | int | null | string
125 125
     {
126 126
         $value = self::get($name);
127 127
         self::forget($name);
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
      *
166 166
      * @return void
167 167
      */
168
-    public static function put(string $name, array|bool|int|null|string $value): void
168
+    public static function put(string $name, array | bool | int | null | string $value): void
169 169
     {
170 170
         $_SESSION[$name] = $value;
171 171
     }
Please login to merge, or discard this patch.
app/Webtrees.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -296,7 +296,7 @@
 block discarded – undo
296 296
      * @param string        $abstract
297 297
      * @param string|object $concrete
298 298
      */
299
-    public static function set(string $abstract, string|object $concrete): void
299
+    public static function set(string $abstract, string | object $concrete): void
300 300
     {
301 301
         if (is_string($concrete)) {
302 302
             Container::getInstance()->bind($abstract, $concrete);
Please login to merge, or discard this patch.
app/Date/AbstractCalendarDate.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
      *
81 81
      * @param array<string>|int|AbstractCalendarDate $date
82 82
      */
83
-    protected function __construct(array|int|AbstractCalendarDate $date)
83
+    protected function __construct(array | int | AbstractCalendarDate $date)
84 84
     {
85 85
         // Construct from an integer (a julian day number)
86 86
         if (is_int($date)) {
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
             $this->month = static::MONTH_TO_NUMBER[$date[1]] ?? 0;
98 98
 
99 99
             if ($this->month === 0) {
100
-                $this->day   = 0;
100
+                $this->day = 0;
101 101
             }
102 102
 
103 103
             $this->year = $this->extractYear($date[0]);
Please login to merge, or discard this patch.
app/I18N.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -269,7 +269,7 @@  discard block
 block discarded – undo
269 269
      *
270 270
      * @return string
271 271
      */
272
-    public static function digits(string|int $n): string
272
+    public static function digits(string | int $n): string
273 273
     {
274 274
         return self::$locale->digits((string) $n);
275 275
     }
@@ -324,7 +324,7 @@  discard block
 block discarded – undo
324 324
 
325 325
             self::$language = $module_service
326 326
                 ->findByInterface(ModuleLanguageInterface::class)
327
-                ->first(fn (ModuleLanguageInterface $module): bool => $module->locale()->languageTag() === $code);
327
+                ->first(fn(ModuleLanguageInterface $module): bool => $module->locale()->languageTag() === $code);
328 328
         }
329 329
 
330 330
         // Create a translator
@@ -565,10 +565,10 @@  discard block
 block discarded – undo
565 565
     public static function comparator(): Closure
566 566
     {
567 567
         if (self::$collator instanceof Collator) {
568
-            return static fn (string $x, string $y): int => (int) self::$collator->compare($x, $y);
568
+            return static fn(string $x, string $y): int => (int) self::$collator->compare($x, $y);
569 569
         }
570 570
 
571
-        return static fn (string $x, string $y): int => strcmp(self::strtolower($x), self::strtolower($y));
571
+        return static fn(string $x, string $y): int => strcmp(self::strtolower($x), self::strtolower($y));
572 572
     }
573 573
 
574 574
 
Please login to merge, or discard this patch.