diff --git a/phpBB/includes/functions_admin.php b/phpBB/includes/functions_admin.php index a94504d3d2..ee2d432818 100644 --- a/phpBB/includes/functions_admin.php +++ b/phpBB/includes/functions_admin.php @@ -1935,10 +1935,7 @@ function split_sql_file($sql, $delimiter) $sql = str_replace("\r" , '', $sql); $data = preg_split('/' . preg_quote($delimiter, '/') . '$/m', $sql); - foreach ($data as $key => $value) - { - $data[$key] = trim($value); - } + $data = array_map('trim', $data); // The empty case $end_data = end($data);