Code Duplication    Length = 7-7 lines in 2 locations

src/Eccube/Controller/Admin/Store/PluginController.php 1 location

@@ 524-530 (lines=7) @@
521
522
                        // promotionアイテム
523
                        $i = 0;
524
                        foreach ($items as $item) {
525
                            if ($item['promotion'] == 1) {
526
                                $promotionItems[] = $item;
527
                                unset($items[$i]);
528
                            }
529
                            $i++;
530
                        }
531
532
                    } else {
533
                        $message = $data['error_code'].' : '.$data['error_message'];

src/Eccube/Controller/Admin/Store/OwnerStoreController.php 1 location

@@ 134-140 (lines=7) @@
131
132
                    // Promotion item
133
                    $i = 0;
134
                    foreach ($items as $item) {
135
                        if ($item['promotion'] == 1) {
136
                            $promotionItems[] = $item;
137
                            unset($items[$i]);
138
                        }
139
                        $i++;
140
                    }
141
                } else {
142
                    $message = $data['error_code'] . ' : ' . $data['error_message'];
143
                }