Skip to content

Commit 9b86600

Browse files
authored
Fix null default configuration (#274)
1 parent fd6a285 commit 9b86600

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/Configuration.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,16 @@ public static function create(array $options)
8383
}
8484
}
8585

86+
foreach (self::DEFAULT_OPTIONS as $option => $defaultValue) {
87+
if (isset($options[$option])) {
88+
continue;
89+
}
90+
91+
$options[$option] = $defaultValue;
92+
}
93+
8694
$configuration = new Configuration();
87-
$configuration->data = \array_merge(self::DEFAULT_OPTIONS, $options);
95+
$configuration->data = $options;
8896

8997
return $configuration;
9098
}

0 commit comments

Comments
 (0)