Skip to content
Snippets Groups Projects
Commit 53ffa37c authored by Ievgen Shakhsuvarov's avatar Ievgen Shakhsuvarov
Browse files

MAGETWO-83977: Handle empty or incorrect lines in a language CSV #12304

 - Merge Pull Request magento/magento2#12304 from FreekVandeursen/magento2:bugfix/language-pack-empty-line
 - Merged commits:
   1. 470c257f
   2. 3d1d0274
   3. 723452c7
parents f2f94cf3 723452c7
No related merge requests found
four and 75/100,4.75 four and 75/100,4.75
four and 5/10,4.50 four and 5/10,4.50
\ No newline at end of file
...@@ -193,7 +193,9 @@ class Dictionary ...@@ -193,7 +193,9 @@ class Dictionary
foreach ($foundCsvFiles as $foundCsvFile) { foreach ($foundCsvFiles as $foundCsvFile) {
$file = $directoryRead->openFile($foundCsvFile); $file = $directoryRead->openFile($foundCsvFile);
while (($row = $file->readCsv()) !== false) { while (($row = $file->readCsv()) !== false) {
$result[$row[0]] = $row[1]; if (is_array($row) && count($row) > 1) {
$result[$row[0]] = $row[1];
}
} }
} }
} }
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment