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

application/modules/seo/handlers/GoogleEcommerceHandler.php 1 location

@@ 28-84 (lines=57) @@
25
    /**
26
     *
27
     */
28
    static public function installHandlers(ActionEvent $event)
29
    {
30
        $currency = \Yii::$app->getModule('seo')->analytics['ecGoogle']['currency'];
31
        if (AnalyticsHandler::CURRENCY_MAIN === intval($currency)) {
32
            static::$currency = CurrencyHelper::getMainCurrency();
33
        } elseif (AnalyticsHandler::CURRENCY_USER === intval($currency)) {
34
            static::$currency = CurrencyHelper::getUserCurrency();
35
        } else {
36
            static::$currency = CurrencyHelper::findCurrencyByIso($currency);
37
        }
38
39
        $route = implode('/', [
40
            $event->action->controller->module->id,
41
            $event->action->controller->id,
42
            $event->action->id
43
        ]);
44
45
        Event::on(
46
            CartController::className(),
47
            CartController::EVENT_ACTION_ADD,
48
            [self::className(), 'handleCartAdd'],
49
            false
50
        );
51
52
        Event::on(
53
            CartController::className(),
54
            CartController::EVENT_ACTION_REMOVE,
55
            [self::className(), 'handleRemoveFromCart'],
56
            false
57
        );
58
59
        Event::on(
60
            CartController::className(),
61
            CartController::EVENT_ACTION_QUANTITY,
62
            [self::className(), 'handleChangeQuantity'],
63
            false
64
        );
65
66
        Event::on(
67
            CartController::className(),
68
            CartController::EVENT_ACTION_CLEAR,
69
            [self::className(), 'handleClearCart'],
70
            false
71
        );
72
73
        Event::on(
74
            Controller::className(),
75
            Controller::EVENT_PRE_DECORATOR,
76
            [self::className(), 'handleProductShow']
77
        );
78
79
        if ('shop/cart/index' === $route) {
80
            self::handleCartIndex();
81
        }
82
83
        GoogleAnalyticsAssets::register(\Yii::$app->getView());
84
    }
85
86
    /**
87
     * @param CartActionEvent $event

application/modules/seo/handlers/YandexEcommerceHandler.php 1 location

@@ 27-83 (lines=57) @@
24
    /**
25
     * Install handlers
26
     */
27
    static public function installHandlers(ActionEvent $event)
28
    {
29
        $currency = \Yii::$app->getModule('seo')->analytics['ecYandex']['currency'];
30
        if (AnalyticsHandler::CURRENCY_MAIN === intval($currency)) {
31
            static::$currency = CurrencyHelper::getMainCurrency();
32
        } elseif (AnalyticsHandler::CURRENCY_USER === intval($currency)) {
33
            static::$currency = CurrencyHelper::getUserCurrency();
34
        } else {
35
            static::$currency = CurrencyHelper::findCurrencyByIso($currency);
36
        }
37
38
        $route = implode('/', [
39
            $event->action->controller->module->id,
40
            $event->action->controller->id,
41
            $event->action->id
42
        ]);
43
44
        Event::on(
45
            CartController::className(),
46
            CartController::EVENT_ACTION_ADD,
47
            [self::className(), 'handleCartAdd'],
48
            false
49
        );
50
51
        Event::on(
52
            CartController::className(),
53
            CartController::EVENT_ACTION_REMOVE,
54
            [self::className(), 'handleRemoveFromCart'],
55
            false
56
        );
57
58
        Event::on(
59
            CartController::className(),
60
            CartController::EVENT_ACTION_QUANTITY,
61
            [self::className(), 'handleChangeQuantity'],
62
            false
63
        );
64
65
        Event::on(
66
            CartController::className(),
67
            CartController::EVENT_ACTION_CLEAR,
68
            [self::className(), 'handleClearCart'],
69
            false
70
        );
71
72
        Event::on(
73
            Controller::className(),
74
            Controller::EVENT_PRE_DECORATOR,
75
            [self::className(), 'handleProductShow']
76
        );
77
78
        if ('shop/cart/index' === $route) {
79
            self::handleCartIndex();
80
        }
81
82
        YandexAnalyticsAssets::register(\Yii::$app->getView());
83
    }
84
85
    /**
86
     * @param CartActionEvent $event