Code Duplication    Length = 8-8 lines in 2 locations

src/controllers/HdomainController.php 1 location

@@ 131-138 (lines=8) @@
128
                    $action = $event->sender;
129
                    $type = Yii::$app->request->post('type');
130
                    $comment = Yii::$app->request->post('comment');
131
                    if (!empty($type)) {
132
                        foreach ($action->collection->models as $model) {
133
                            $model->setAttributes([
134
                                'type' => $type,
135
                                'comment' => $comment,
136
                            ]);
137
                        }
138
                    }
139
                },
140
            ],
141
            'bulk-enable-block-modal' => [

src/controllers/AccountController.php 1 location

@@ 140-147 (lines=8) @@
137
                    $action = $event->sender;
138
                    $type = Yii::$app->request->post('type');
139
                    $comment = Yii::$app->request->post('comment');
140
                    if (!empty($type)) {
141
                        foreach ($action->collection->models as $model) {
142
                            $model->setAttributes([
143
                                'type' => $type,
144
                                'comment' => $comment,
145
                            ]);
146
                        }
147
                    }
148
                },
149
            ],
150
            'bulk-enable-block-modal' => [