@@ -20,7 +20,7 @@ |
||
| 20 | 20 | /** |
| 21 | 21 | * Ensure the timezone is set; |
| 22 | 22 | */ |
| 23 | -if (version_compare(phpversion(),'5.3.0') >= 0) { |
|
| 23 | +if (version_compare(phpversion(), '5.3.0') >= 0) { |
|
| 24 | 24 | $tz = @ini_get('date.timezone'); |
| 25 | 25 | if (empty($tz)) { |
| 26 | 26 | date_default_timezone_set(@date_default_timezone_get()); |
@@ -77,22 +77,22 @@ discard block |
||
| 77 | 77 | $self = new Orchestrator(); |
| 78 | 78 | $self->setMode(0755); |
| 79 | 79 | |
| 80 | - if (file_exists($package_path . 'public')) { |
|
| 80 | + if (file_exists($package_path.'public')) { |
|
| 81 | 81 | $destination = MODX_BASE_PATH; |
| 82 | 82 | if (isset($config['LCI_ORCHESTRATOR_PUBLIC_PATH']) && file_exists($config['LCI_ORCHESTRATOR_PUBLIC_PATH'])) { |
| 83 | 83 | $destination = $config['LCI_ORCHESTRATOR_PUBLIC_PATH']; |
| 84 | 84 | } |
| 85 | 85 | |
| 86 | - $self->copyDirectory($package_path . 'public', $destination); |
|
| 86 | + $self->copyDirectory($package_path.'public', $destination); |
|
| 87 | 87 | } |
| 88 | 88 | |
| 89 | - if (file_exists($package_path . 'assets')) { |
|
| 89 | + if (file_exists($package_path.'assets')) { |
|
| 90 | 90 | $destination = MODX_ASSETS_PATH; |
| 91 | 91 | if (isset($config['LCI_ORCHESTRATOR_ASSETS_PATH']) && file_exists($config['LCI_ORCHESTRATOR_ASSETS_PATH'])) { |
| 92 | 92 | $destination = $config['LCI_ORCHESTRATOR_ASSETS_PATH']; |
| 93 | 93 | } |
| 94 | 94 | |
| 95 | - $self->copyDirectory($package_path . 'assets', $destination); |
|
| 95 | + $self->copyDirectory($package_path.'assets', $destination); |
|
| 96 | 96 | } |
| 97 | 97 | } |
| 98 | 98 | |
@@ -102,7 +102,7 @@ discard block |
||
| 102 | 102 | * |
| 103 | 103 | * @throws \LCI\Blend\Exception\MigratorException |
| 104 | 104 | */ |
| 105 | - public static function installComposerPackage($project, $type='master') |
|
| 105 | + public static function installComposerPackage($project, $type = 'master') |
|
| 106 | 106 | { |
| 107 | 107 | $path = static ::getPackagePath($project); |
| 108 | 108 | |
@@ -115,7 +115,7 @@ discard block |
||
| 115 | 115 | * @param string $type |
| 116 | 116 | * @throws \LCI\Blend\Exception\MigratorException |
| 117 | 117 | */ |
| 118 | - public static function updateComposerPackage($project, $type='master') |
|
| 118 | + public static function updateComposerPackage($project, $type = 'master') |
|
| 119 | 119 | { |
| 120 | 120 | $path = static ::getPackagePath($project); |
| 121 | 121 | |
@@ -128,7 +128,7 @@ discard block |
||
| 128 | 128 | * @param string $type |
| 129 | 129 | * @throws \LCI\Blend\Exception\MigratorException |
| 130 | 130 | */ |
| 131 | - public static function uninstallComposerPackage($project, $type='master') |
|
| 131 | + public static function uninstallComposerPackage($project, $type = 'master') |
|
| 132 | 132 | { |
| 133 | 133 | $path = static ::getPackagePath($project); |
| 134 | 134 | |
@@ -144,7 +144,7 @@ discard block |
||
| 144 | 144 | * |
| 145 | 145 | * @throws \LCI\Blend\Exception\MigratorException |
| 146 | 146 | */ |
| 147 | - protected static function runMigrations($project, $config=[], $method='up', $type='master') |
|
| 147 | + protected static function runMigrations($project, $config = [], $method = 'up', $type = 'master') |
|
| 148 | 148 | { |
| 149 | 149 | /** @var \LCI\MODX\Console\Console $console */ |
| 150 | 150 | $console = new Console(); |
@@ -170,7 +170,7 @@ discard block |
||
| 170 | 170 | * @param bool $include_src |
| 171 | 171 | * @return string |
| 172 | 172 | */ |
| 173 | - protected static function getPackagePath($package='lci/orchestrator', $include_src = true) |
|
| 173 | + protected static function getPackagePath($package = 'lci/orchestrator', $include_src = true) |
|
| 174 | 174 | { |
| 175 | 175 | if (empty(static::$modx)) { |
| 176 | 176 | /** @var \LCI\MODX\Console\Console $console */ |
@@ -183,10 +183,10 @@ discard block |
||
| 183 | 183 | null, |
| 184 | 184 | (defined('MODX_CORE_PATH') ? MODX_CORE_PATH.'vendor/' : dirname(__DIR__)) |
| 185 | 185 | ); |
| 186 | - $path .= $package . DIRECTORY_SEPARATOR; |
|
| 186 | + $path .= $package.DIRECTORY_SEPARATOR; |
|
| 187 | 187 | |
| 188 | 188 | if ($include_src) { |
| 189 | - $path .= 'src' . DIRECTORY_SEPARATOR; |
|
| 189 | + $path .= 'src'.DIRECTORY_SEPARATOR; |
|
| 190 | 190 | } |
| 191 | 191 | |
| 192 | 192 | return $path; |
@@ -12,7 +12,7 @@ |
||
| 12 | 12 | class Application extends \LCI\MODX\Console\Application |
| 13 | 13 | { |
| 14 | 14 | // @see http://patorjk.com/software/taag/#p=display&f=Slant&t=Console |
| 15 | - protected static $logo = __DIR__ . '/art/orchestrator.txt'; |
|
| 15 | + protected static $logo = __DIR__.'/art/orchestrator.txt'; |
|
| 16 | 16 | |
| 17 | 17 | protected static $name = 'Orchestrator Console'; |
| 18 | 18 | |
@@ -80,7 +80,7 @@ |
||
| 80 | 80 | foreach ($commands as $command) { |
| 81 | 81 | $class = new $command(); |
| 82 | 82 | |
| 83 | - if (is_object($class) ) { |
|
| 83 | + if (is_object($class)) { |
|
| 84 | 84 | if (method_exists($class, 'setConsole')) { |
| 85 | 85 | $class->setConsole($this->console); |
| 86 | 86 | } |
@@ -43,7 +43,7 @@ |
||
| 43 | 43 | |
| 44 | 44 | if ($saved) { |
| 45 | 45 | $this->blender->outSuccess('orchestrator MediaSource has been installed'); |
| 46 | - } else { |
|
| 46 | + } else { |
|
| 47 | 47 | $this->blender->out('orchestrator MediaSource was not installed', true); |
| 48 | 48 | } |
| 49 | 49 | |
@@ -11,7 +11,7 @@ |
||
| 11 | 11 | // already loaded do nothing |
| 12 | 12 | } else { |
| 13 | 13 | /** @var string $file */ |
| 14 | - $file = $modx->getOption('orchestrator.vendor_path', null, MODX_CORE_PATH . 'components/orchestrator/vendor/') . 'autoload.php'; |
|
| 14 | + $file = $modx->getOption('orchestrator.vendor_path', null, MODX_CORE_PATH.'components/orchestrator/vendor/').'autoload.php'; |
|
| 15 | 15 | |
| 16 | 16 | if (file_exists($file)) { |
| 17 | 17 | require_once $file; |
@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | $composer = $event->getComposer(); |
| 29 | 29 | |
| 30 | 30 | $vendorDir = $composer->getConfig()->get('vendor-dir'); |
| 31 | - require $vendorDir . '/autoload.php'; |
|
| 31 | + require $vendorDir.'/autoload.php'; |
|
| 32 | 32 | |
| 33 | 33 | Orchestrator::installComposerPackage('lci/blend'); |
| 34 | 34 | Orchestrator::install(); |
@@ -54,7 +54,7 @@ discard block |
||
| 54 | 54 | /** @var Composer $composer */ |
| 55 | 55 | $composer = $event->getComposer(); |
| 56 | 56 | $vendorDir = $composer->getConfig()->get('vendor-dir'); |
| 57 | - require $vendorDir . '/autoload.php'; |
|
| 57 | + require $vendorDir.'/autoload.php'; |
|
| 58 | 58 | |
| 59 | 59 | Orchestrator::install(); |
| 60 | 60 | Orchestrator::updateComposerPackage('lci/blend'); |
@@ -90,8 +90,8 @@ discard block |
||
| 90 | 90 | // this is the root composer.json data |
| 91 | 91 | $vendorDir = $composer->getConfig()->get('vendor-dir'); |
| 92 | 92 | |
| 93 | - if (file_exists($vendorDir . '/autoload.php')) { |
|
| 94 | - require $vendorDir . '/autoload.php'; |
|
| 93 | + if (file_exists($vendorDir.'/autoload.php')) { |
|
| 94 | + require $vendorDir.'/autoload.php'; |
|
| 95 | 95 | } |
| 96 | 96 | |
| 97 | 97 | if ($currentPackage->getName() == 'lci\orchestrator') { |