Skip to content

Commit

Permalink
Make included files compatible with PHP 5.4
Browse files Browse the repository at this point in the history
  • Loading branch information
mlocati committed Oct 4, 2016
1 parent 9bdde7e commit 35ddaed
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Util/ConfigFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,9 @@ private function readFile($filename)
if ($contents === false) {
throw new Exception('Failed to read file '.$filename);
}

$this->contents = str_replace(array("\r\n", "\r"), "\n", $contents);
$contents = str_replace(array("\r\n", "\r"), "\n", $contents);
$contents = preg_replace('/([a-z_\\\\]+)::class\b/i', "'\\1'", $contents);
$this->contents = $contents;
}

/**
Expand Down

0 comments on commit 35ddaed

Please sign in to comment.