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 = 11-15 lines in 2 locations

src/Structure.php 2 locations

@@ 204-218 (lines=15) @@
201
        }
202
203
        // class name is string
204
        if(is_string($className)) {
205
            $list = array_map(
206
                function($dataItem) use($className) {
207
                    $listItemStructure = new $className();
208
                    if(!($listItemStructure instanceof Structure)) {
209
                        throw new Exception('Wrong structure class specified');
210
                    }
211
                    $listItemStructure->mergeUnmodified($dataItem);
212
                    return $listItemStructure;
213
                },
214
                $data
215
            );
216
217
            return $list;
218
        }
219
220
        // class name id callable
221
        if(is_callable($className)) {
@@ 221-231 (lines=11) @@
218
        }
219
220
        // class name id callable
221
        if(is_callable($className)) {
222
            return array_map(function($dataItem) use( $className) {
223
                $classNameString = $className($dataItem);
224
                $listItemStructure = new $classNameString;
225
                if(!($listItemStructure instanceof Structure)) {
226
                    throw new Exception('Wrong structure class specified');
227
                }
228
229
                return $listItemStructure->merge($dataItem);
230
            }, $data);
231
        }
232
233
        throw new Exception('Wrong class name specified. Use string or closure');
234
    }