Skip to content

Commit 3bf049b

Browse files
author
jmontoya
committed
Adding trim in the server ini_parser::get_ini_string() function
1 parent 0ab659d commit 3bf049b

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

server/lib/classes/ini_parser.inc.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,11 @@ function get_ini_string($file) {
5858
foreach($this->config as $section => $data) {
5959
$content .= "[$section]\n";
6060
foreach($data as $item => $value) {
61-
if($value != '') $content .= "$item=$value\n";
61+
if($value != '') {
62+
$value = trim($value);
63+
$item = trim($item);
64+
$content .= "$item=$value\n";
65+
}
6266
}
6367
}
6468
return $content;

0 commit comments

Comments
 (0)