Skip to content
This repository has been archived by the owner on Feb 27, 2023. It is now read-only.

Commit

Permalink
Merge pull request vierbergenlars#55 from AOEpeople/master
Browse files Browse the repository at this point in the history
[TASK] Updates Autoloading to match when required from other libraries/tools
  • Loading branch information
vierbergenlars authored Oct 3, 2018
2 parents 47e8d20 + 86aec35 commit b6b8ec5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
8 changes: 7 additions & 1 deletion bin/semver
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,13 @@

namespace vierbergenlars\SemVer\Application\SemVer;

require __DIR__ . '/../vendor/autoload.php';
if (file_exists(__DIR__ . '/../vendor/autoload.php')) {
require_once __DIR__ . '/../vendor/autoload.php';
} else {
if (file_exists(__DIR__ . '/../../../autoload.php')) {
require_once __DIR__ . '/../../../autoload.php';
}
}

use vierbergenlars\SemVer\version;
use vierbergenlars\SemVer\expression;
Expand Down
8 changes: 7 additions & 1 deletion bin/update-versions
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,13 @@

namespace vierbergenlars\SemVer\Application\UpdateVersions;

require __DIR__ . '/../vendor/autoload.php';
if (file_exists(__DIR__ . '/../vendor/autoload.php')) {
require_once __DIR__ . '/../vendor/autoload.php';
} else {
if (file_exists(__DIR__ . '/../../../autoload.php')) {
require_once __DIR__ . '/../../../autoload.php';
}
}

use vierbergenlars\SemVer\version;
use vierbergenlars\SemVer\expression;
Expand Down

0 comments on commit b6b8ec5

Please sign in to comment.