Code Duplication    Length = 8-10 lines in 2 locations

typo3/sysext/impexp/Classes/ImportExport.php 2 locations

@@ 321-330 (lines=10) @@
318
            $viewData['dat'] = $this->dat;
319
            $viewData['update'] = $this->update;
320
            $viewData['showDiff'] = $this->showDiff;
321
            if (!empty($lines)) {
322
                foreach ($lines as &$r) {
323
                    $r['controls'] = $this->renderControls($r);
324
                    $r['fileSize'] = GeneralUtility::formatSize($r['size']);
325
                    $r['message'] = ($r['msg'] && !$this->doesImport ? '<span class="text-danger">' . htmlspecialchars($r['msg']) . '</span>' : '');
326
                }
327
                $viewData['pagetreeLines'] = $lines;
328
            } else {
329
                $viewData['pagetreeLines'] = [];
330
            }
331
        }
332
        // Print remaining records that were not contained inside the page tree:
333
        if (is_array($this->remainHeader['records'])) {
@@ 339-346 (lines=8) @@
336
                $this->traversePageRecords($this->remainHeader['records']['pages'], $lines);
337
            }
338
            $this->traverseAllRecords($this->remainHeader['records'], $lines);
339
            if (!empty($lines)) {
340
                foreach ($lines as &$r) {
341
                    $r['controls'] = $this->renderControls($r);
342
                    $r['fileSize'] = GeneralUtility::formatSize($r['size']);
343
                    $r['message'] = ($r['msg'] && !$this->doesImport ? '<span class="text-danger">' . htmlspecialchars($r['msg']) . '</span>' : '');
344
                }
345
                $viewData['remainingRecords'] = $lines;
346
            }
347
        }
348
349
        return $viewData;