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

application/modules/page/backend/PageController.php 1 location

@@ 320-338 (lines=19) @@
317
                )->execute();
318
            }
319
            $newModelProps = [];
320
            foreach (array_keys($model->propertyGroups) as $key) {
321
                $opg = new ObjectPropertyGroup();
322
                $opg->attributes = [
323
                    'object_id' => $object->id,
324
                    'object_model_id' => $newModel->id,
325
                    'property_group_id' => $key,
326
                ];
327
                $opg->save();
328
                $props = Property::getForGroupId($key);
329
                foreach ($props as $prop) {
330
                    $propValues = $model->getPropertyValuesByPropertyId($prop->id);
331
                    if ($propValues !== null) {
332
                        foreach ($propValues->values as $val) {
333
                            $valueToSave = ArrayHelper::getValue($val, 'psv_id', $val['value']);
334
                            $newModelProps[$prop->key][] = $valueToSave;
335
                        }
336
                    }
337
                }
338
            }
339
            $newModel->saveProperties(
340
                [
341
                    'Properties_Page_' . $newModel->id => $newModelProps,

application/modules/shop/controllers/BackendProductController.php 1 location

@@ 530-548 (lines=19) @@
527
                )->execute();
528
            }
529
            $newModelProps = [];
530
            foreach (array_keys($model->propertyGroups) as $key) {
531
                $opg = new ObjectPropertyGroup();
532
                $opg->attributes = [
533
                    'object_id' => $object->id,
534
                    'object_model_id' => $newModel->id,
535
                    'property_group_id' => $key,
536
                ];
537
                $opg->save();
538
                $props = Property::getForGroupId($key);
539
                foreach ($props as $prop) {
540
                    $propValues = $model->getPropertyValuesByPropertyId($prop->id);
541
                    if ($propValues !== null) {
542
                        foreach ($propValues->values as $val) {
543
                            $valueToSave = ArrayHelper::getValue($val, 'psv_id', $val['value']);
544
                            $newModelProps[$prop->key][] = $valueToSave;
545
                        }
546
                    }
547
                }
548
            }
549
            $newModel->saveProperties(
550
                [
551
                    'Properties_Product_' . $newModel->id => $newModelProps,