mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-28 16:24:05 +02:00
ConfigDiff: more context, fix diff with empty
fixes #12262 fixes #12263
This commit is contained in:
parent
ce1c6f3099
commit
7655ad451a
@ -22,10 +22,20 @@ class ConfigDiff
|
||||
{
|
||||
require_once dirname(__DIR__) . '/vendor/php-diff/lib/Diff.php';
|
||||
|
||||
$this->a = explode("\n", (string) $a);
|
||||
$this->b = explode("\n", (string) $b);
|
||||
if (empty($a)) {
|
||||
$this->a = array();
|
||||
} else {
|
||||
$this->a = explode("\n", (string) $a);
|
||||
}
|
||||
|
||||
if (empty($b)) {
|
||||
$this->b = array();
|
||||
} else {
|
||||
$this->b = explode("\n", (string) $b);
|
||||
}
|
||||
|
||||
$options = array(
|
||||
'context' => 5,
|
||||
// 'ignoreWhitespace' => true,
|
||||
// 'ignoreCase' => true,
|
||||
);
|
||||
|
Loading…
x
Reference in New Issue
Block a user