Skip to content

Commit

Permalink
Added composer patch to get.php, ref. OpenMage#3453 (OpenMage#3476)
Browse files Browse the repository at this point in the history
  • Loading branch information
fballiano authored Sep 5, 2023
1 parent 8558c35 commit 888e566
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions get.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,20 +28,30 @@
/**
* Set include path
*/

$paths = [];
$paths[] = $bp . $ds . 'app' . $ds . 'code' . $ds . 'local';
$paths[] = $bp . $ds . 'app' . $ds . 'code' . $ds . 'community';
$paths[] = $bp . $ds . 'app' . $ds . 'code' . $ds . 'core';
$paths[] = $bp . $ds . 'lib';

$appPath = implode($ps, $paths);
set_include_path($appPath . $ps . get_include_path());

include_once 'Mage/Core/functions.php';
include_once 'Varien/Autoload.php';

Varien_Autoload::register();

/** AUTOLOADER PATCH **/
$autoloaderPath = getenv('COMPOSER_VENDOR_PATH');
if (!$autoloaderPath) {
$autoloaderPath = dirname($bp) . $ds . 'vendor';
if (!is_dir($autoloaderPath)) {
$autoloaderPath = $bp . $ds . 'vendor';
}
}
require $autoloaderPath . $ds . 'autoload.php';
/** AUTOLOADER PATCH **/

$varDirectory = $bp . $ds . Mage_Core_Model_Config_Options::VAR_DIRECTORY;

$configCacheFile = $varDirectory . $ds . 'resource_config.json';
Expand Down

0 comments on commit 888e566

Please sign in to comment.