Skip to content

Commit

Permalink
Update Request normalizer:
Browse files Browse the repository at this point in the history
- replace ObjectHelper::getDirectory() by __DIR__ constant
  • Loading branch information
webeweb committed Nov 6, 2019
1 parent c166014 commit 5f2ff89
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/Normalizer/RequestNormalizer.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
use InvalidArgumentException;
use Symfony\Component\Yaml\Yaml;
use WBW\Library\Core\Argument\ArrayHelper;
use WBW\Library\Core\Argument\ObjectHelper;
use WBW\Library\SMSMode\API\RequestInterface;

/**
Expand All @@ -38,9 +37,8 @@ class RequestNormalizer {
*/
public function __construct() {

$directory = ObjectHelper::getDirectory($this);
$filename = $directory . "/../Resources/config/request-normalizer.yml";
$content = file_get_contents(realpath($filename));
$filename = __DIR__ . "/../Resources/config/request-normalizer.yml";
$content = file_get_contents(realpath($filename));

$this->setConfiguration(Yaml::parse($content));
}
Expand Down

0 comments on commit 5f2ff89

Please sign in to comment.