GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Code Duplication    Length = 12-15 lines in 2 locations

Map.php 2 locations

@@ 354-368 (lines=15) @@
351
    {
352
        $map = $this->clear();
353
354
        foreach ($this->keys as $index => $key) {
355
            $return = $function(
356
                $key,
357
                $this->values->get($index)
358
            );
359
360
            if ($return instanceof Pair) {
361
                $key = $return->key();
362
                $value = $return->value();
363
            } else {
364
                $value = $return;
365
            }
366
367
            $map = $map->put($key, $value);
368
        }
369
370
        return $map;
371
    }
@@ 465-476 (lines=12) @@
462
        $truthy = $this->clear();
463
        $falsy = $this->clear();
464
465
        foreach ($this->keys as $index => $key) {
466
            $return = $predicate(
467
                $key,
468
                $value = $this->values->get($index)
469
            );
470
471
            if ($return === true) {
472
                $truthy = $truthy->put($key, $value);
473
            } else {
474
                $falsy = $falsy->put($key, $value);
475
            }
476
        }
477
478
        return (new self('bool', MapInterface::class))
479
            ->put(true, $truthy)