Skip to content

Commit

Permalink
replace SpycYAMLParser with Symfony Yaml parser, fix #755
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidBruchmann authored and Philipp Kuhlmay committed Apr 5, 2024
1 parent b43a95e commit 2677521
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 1,186 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
/composer.lock
/.php_cs.cache
sass-lint.html
*.*~

# created by rendering Documentation with Docker
/Documentation-GENERATED-temp
Expand Down
1 change: 0 additions & 1 deletion .php-cs-fixer.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@
'ext_localconf.php',
'ext_tables.php',
'ext_emconf.php',
'SpycYAMLParser.php',
])
->depth('> 1')
;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
namespace EBT\ExtensionBuilder\Configuration;

use EBT\ExtensionBuilder\Domain\Model\Extension;
use EBT\ExtensionBuilder\Utility\SpycYAMLParser;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
use RectorPrefix202306\Tracy\Debugger;
Expand All @@ -36,6 +35,7 @@
use TYPO3\CMS\Extbase\Configuration\ConfigurationManagerInterface;
use TYPO3\CMS\Extbase\Persistence\Generic\Mapper\DataMapper;
use TYPO3\CMS\Extbase\Utility\DebuggerUtility;
use Symfony\Component\Yaml\Yaml;

/**
* Load settings from yaml file and from TYPO3_CONF_VARS extConf
Expand Down Expand Up @@ -148,7 +148,7 @@ public function getExtensionSettings(string $extensionKey, string $extensionStor
if (!file_exists($settingsFile)) {
return [];
}
return SpycYAMLParser::YAMLLoadString(file_get_contents($settingsFile));
return Yaml::parseFile($settingsFile);
}

/**
Expand Down Expand Up @@ -436,7 +436,7 @@ protected function findModuleIndexByRelationUid(
}

if (
isset($modules[$supposedModuleIndex]['value']['relationGroup']['relations'][$supposedRelationIndex]['uid'])
isset($modules[$supposedModuleIndex]['value']['relationGroup']['relations'][$supposedRelationIndex]['uid'])
&& $modules[$supposedModuleIndex]['value']['relationGroup']['relations'][$supposedRelationIndex]['uid'] === $uid
) {
$result['terminal'] = 'relationWire_' . $supposedRelationIndex;
Expand Down
Loading

0 comments on commit 2677521

Please sign in to comment.