Skip to content

Commit

Permalink
Reorganize PHP extension requirements in composer.json (#49)
Browse files Browse the repository at this point in the history
  • Loading branch information
SmetDenis committed Mar 22, 2024
1 parent 0b9863c commit 4630245
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions composer.json
Expand Up @@ -48,11 +48,7 @@
],

"require" : {
"php" : "^8.1",
"ext-posix" : "*",
"ext-filter" : "*",
"ext-dom" : "*",
"ext-gd" : "*"
"php" : "^8.1"
},

"require-dev" : {
Expand All @@ -66,7 +62,11 @@
"symfony/process" : "For Cli::exec() method only",
"symfony/polyfill-mbstring" : "For UTF-8 if ext-mbstring disabled",
"jbzoo/data" : ">=4.0",
"ext-intl" : "*"
"ext-intl" : "*",
"ext-posix" : "*",
"ext-filter" : "*",
"ext-dom" : "*",
"ext-gd" : "*"
},

"autoload" : {
Expand Down
4 changes: 2 additions & 2 deletions src/Xml.php
Expand Up @@ -50,8 +50,8 @@ public static function createFromString(?string $source = null, bool $preserveWh

$document->preserveWhiteSpace = $preserveWhiteSpace;

if (!isStrEmpty($source)) {
$document->loadXML($source ?? '');
if ($source !== '' && $source !== null) {
$document->loadXML($source);
}

$document->xmlVersion = self::VERSION;
Expand Down

0 comments on commit 4630245

Please sign in to comment.