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 = 15-18 lines in 3 locations

src/Common/Api/OperatorTrait.php 1 location

@@ 137-151 (lines=15) @@
134
    /**
135
     * {@inheritDoc}
136
     */
137
    public function model(string $class, $data = null): ResourceInterface
138
    {
139
        $model = new $class($this->client, $this->api);
140
        // @codeCoverageIgnoreStart
141
        if (!$model instanceof ResourceInterface) {
142
            throw new \RuntimeException(sprintf('%s does not implement %s', $class, ResourceInterface::class));
143
        }
144
        // @codeCoverageIgnoreEnd
145
        if ($data instanceof ResponseInterface) {
146
            $model->populateFromResponse($data);
147
        } elseif (is_array($data)) {
148
            $model->populateFromArray($data);
149
        }
150
        return $model;
151
    }
152
}
153

src/Common/Resource/OperatorResource.php 1 location

@@ 130-147 (lines=18) @@
127
    /**
128
     * {@inheritDoc}
129
     */
130
    public function model(string $class, $data = null): ResourceInterface
131
    {
132
        $model = new $class($this->client, $this->api);
133
134
        // @codeCoverageIgnoreStart
135
        if (!$model instanceof ResourceInterface) {
136
            throw new \RuntimeException(sprintf('%s does not implement %s', $class, ResourceInterface::class));
137
        }
138
        // @codeCoverageIgnoreEnd
139
140
        if ($data instanceof ResponseInterface) {
141
            $model->populateFromResponse($data);
142
        } elseif (is_array($data)) {
143
            $model->populateFromArray($data);
144
        }
145
146
        return $model;
147
    }
148
}
149

src/Common/Resource/AbstractResource.php 1 location

@@ 130-147 (lines=18) @@
127
        return $output;
128
    }
129
130
    public function model(string $class, $data = null): ResourceInterface
131
    {
132
        $model = new $class();
133
134
        // @codeCoverageIgnoreStart
135
        if (!$model instanceof ResourceInterface) {
136
            throw new \RuntimeException(sprintf('%s does not implement %s', $class, ResourceInterface::class));
137
        }
138
        // @codeCoverageIgnoreEnd
139
140
        if ($data instanceof ResponseInterface) {
141
            $model->populateFromResponse($data);
142
        } elseif (is_array($data)) {
143
            $model->populateFromArray($data);
144
        }
145
146
        return $model;
147
    }
148
149
    public function serialize(): \stdClass
150
    {