@@ -4,13 +4,13 @@ |
||
| 4 | 4 | |
| 5 | 5 | // Register root dir |
| 6 | 6 | if (getenv('COMPOSER_CONFIGURATION_PATH') === false) { |
| 7 | - putenv('COMPOSER_CONFIGURATION_PATH=' . dirname(dirname(dirname(__DIR__)))); |
|
| 7 | + putenv('COMPOSER_CONFIGURATION_PATH='.dirname(dirname(dirname(__DIR__)))); |
|
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | define('COMPOSER_CONFIGURATION_PATH', getenv('COMPOSER_CONFIGURATION_PATH')); |
| 11 | 11 | |
| 12 | 12 | // Load Composer's autoloader. |
| 13 | -$loader = require __DIR__ . '/../../autoload.php'; |
|
| 13 | +$loader = require __DIR__.'/../../autoload.php'; |
|
| 14 | 14 | |
| 15 | 15 | $autoloader_init = new AutoloaderBootstrap($loader); |
| 16 | 16 | $autoloader_init->register(); |
@@ -136,7 +136,7 @@ |
||
| 136 | 136 | $token_name = $this->getToken(); |
| 137 | 137 | $delimiter = '/'; |
| 138 | 138 | $matches = array(); |
| 139 | - if (preg_match($delimiter . preg_quote($token_name) . '<(.+)>.*' . $delimiter, $this->path, $matches)) { |
|
| 139 | + if (preg_match($delimiter.preg_quote($token_name).'<(.+)>.*'.$delimiter, $this->path, $matches)) { |
|
| 140 | 140 | // Some arguments were found. |
| 141 | 141 | return explode(',', $matches[1]); |
| 142 | 142 | } |
@@ -51,7 +51,7 @@ discard block |
||
| 51 | 51 | $core_path = $this->coreFinder->find($seed); |
| 52 | 52 | |
| 53 | 53 | // Create the RecursiveDirectoryIterator on the core directory. |
| 54 | - $core_directory = new \RecursiveDirectoryIterator($core_path . '/sites', \FilesystemIterator::KEY_AS_PATHNAME | \FilesystemIterator::CURRENT_AS_FILEINFO | \FilesystemIterator::SKIP_DOTS); |
|
| 54 | + $core_directory = new \RecursiveDirectoryIterator($core_path.'/sites', \FilesystemIterator::KEY_AS_PATHNAME | \FilesystemIterator::CURRENT_AS_FILEINFO | \FilesystemIterator::SKIP_DOTS); |
|
| 55 | 55 | // Create an iterator that will go recursively through all the files and |
| 56 | 56 | // directories -because of SELF_FIRST-. |
| 57 | 57 | $files_iterator = new \RecursiveIteratorIterator($core_directory, \RecursiveIteratorIterator::SELF_FIRST); |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | // Check if the current directory corresponds to the contrib we are |
| 66 | 66 | // looking for. |
| 67 | 67 | if ($this->isWantedContrib($dir)) { |
| 68 | - return $this->cleanDirPath($dir->getPathName()) . $this->path; |
|
| 68 | + return $this->cleanDirPath($dir->getPathName()).$this->path; |
|
| 69 | 69 | } |
| 70 | 70 | } |
| 71 | 71 | throw new ClassLoaderException(sprintf('Drupal module "%s" could not be found in the Drupal tree that contains: %s.', $this->moduleName, $seed)); |
@@ -80,7 +80,7 @@ discard block |
||
| 80 | 80 | * TRUE if the contrib is detected. FALSE otherwise. |
| 81 | 81 | */ |
| 82 | 82 | protected function isWantedContrib(\SplFileInfo $dir) { |
| 83 | - $info_file = $this->cleanDirPath($dir->getPathName()) . DIRECTORY_SEPARATOR . $this->moduleName . '.info'; |
|
| 83 | + $info_file = $this->cleanDirPath($dir->getPathName()).DIRECTORY_SEPARATOR.$this->moduleName.'.info'; |
|
| 84 | 84 | return file_exists($info_file); |
| 85 | 85 | } |
| 86 | 86 | |
@@ -22,7 +22,7 @@ discard block |
||
| 22 | 22 | // up and up and up until we reach the Drupal root. |
| 23 | 23 | do { |
| 24 | 24 | if ($this->isDrupalRoot($directory)) { |
| 25 | - return $directory . $this->path; |
|
| 25 | + return $directory.$this->path; |
|
| 26 | 26 | } |
| 27 | 27 | } |
| 28 | 28 | while ($directory = $this->getParentDirectory($directory)); |
@@ -43,12 +43,12 @@ discard block |
||
| 43 | 43 | * TRUE if the passed directory is the Drupal root. |
| 44 | 44 | */ |
| 45 | 45 | protected function isDrupalRoot($directory) { |
| 46 | - if (!empty($directory) && is_dir($directory) && file_exists($directory . DIRECTORY_SEPARATOR . '/index.php')) { |
|
| 46 | + if (!empty($directory) && is_dir($directory) && file_exists($directory.DIRECTORY_SEPARATOR.'/index.php')) { |
|
| 47 | 47 | // Drupal 7 root. |
| 48 | 48 | // We check for the presence of 'modules/field/field.module' to differentiate this from a D6 site |
| 49 | - return (file_exists($directory . DIRECTORY_SEPARATOR . 'includes/common.inc') |
|
| 50 | - && file_exists($directory . DIRECTORY_SEPARATOR . 'misc/drupal.js') |
|
| 51 | - && file_exists($directory . DIRECTORY_SEPARATOR . 'modules/field/field.module')); |
|
| 49 | + return (file_exists($directory.DIRECTORY_SEPARATOR.'includes/common.inc') |
|
| 50 | + && file_exists($directory.DIRECTORY_SEPARATOR.'misc/drupal.js') |
|
| 51 | + && file_exists($directory.DIRECTORY_SEPARATOR.'modules/field/field.module')); |
|
| 52 | 52 | } |
| 53 | 53 | return FALSE; |
| 54 | 54 | } |