fix version file path (#194)

This commit is contained in:
vasilevdm 2020-09-23 11:57:15 +03:00 committed by GitHub
parent 28391f4134
commit 1d9110c364
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -12,7 +12,7 @@ if (!isset($cli_action)) {
// Version // Version
$version = '2.3.0'; $version = '2.3.0';
$indexFile = file_get_contents(realpath(dirname(__FILE__)) . '/../../index.php'); $indexFile = file_get_contents(realpath(dirname(__FILE__)) . '/../../../../index.php');
preg_match("/define\([\s]*['\"]VERSION['\"][\s]*,[\s]*['\"](.*)['\"][\s]*\)[\s]*;/mi", $indexFile, $versionMatches); preg_match("/define\([\s]*['\"]VERSION['\"][\s]*,[\s]*['\"](.*)['\"][\s]*\)[\s]*;/mi", $indexFile, $versionMatches);
if (isset($versionMatches[1])) { if (isset($versionMatches[1])) {