@@ -66,8 +66,8 @@ |
||
| 66 | 66 | * @param string $packageSource |
| 67 | 67 | * @param stdClass $extra |
| 68 | 68 | */ |
| 69 | - public function __construct($name, $version, $packageRepository=null, |
|
| 70 | - $packageSource=null, stdClass $extra=null) { |
|
| 69 | + public function __construct($name, $version, $packageRepository = null, |
|
| 70 | + $packageSource = null, stdClass $extra = null) { |
|
| 71 | 71 | $this->name = $name; |
| 72 | 72 | $this->version = $version; |
| 73 | 73 | |
@@ -137,7 +137,7 @@ discard block |
||
| 137 | 137 | * |
| 138 | 138 | * @return Moodle |
| 139 | 139 | */ |
| 140 | - protected function getMoodle($moodleDirectory=null) { |
|
| 140 | + protected function getMoodle($moodleDirectory = null) { |
|
| 141 | 141 | if ($this->moodle === null) { |
| 142 | 142 | $moodleDirectory = ($moodleDirectory === null) |
| 143 | 143 | ? $this->platform->getWorkingDirectory() : $moodleDirectory; |
@@ -156,7 +156,7 @@ discard block |
||
| 156 | 156 | * |
| 157 | 157 | * @return Project |
| 158 | 158 | */ |
| 159 | - protected function getProject($projectFilename=null, $projectLockFilename=null) { |
|
| 159 | + protected function getProject($projectFilename = null, $projectLockFilename = null) { |
|
| 160 | 160 | $workingDirectory = $this->platform->getWorkingDirectory(); |
| 161 | 161 | |
| 162 | 162 | if ($this->project === null) { |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | * @param ComponentVersion[] $versions |
| 66 | 66 | * @param PackageRepository|null $packageRepository |
| 67 | 67 | */ |
| 68 | - public function __construct($name, $versions, $packageRepository=null) { |
|
| 68 | + public function __construct($name, $versions, $packageRepository = null) { |
|
| 69 | 69 | $this->name = $name; |
| 70 | 70 | $this->versions = $versions; |
| 71 | 71 | |
@@ -126,7 +126,7 @@ discard block |
||
| 126 | 126 | * @return string |
| 127 | 127 | */ |
| 128 | 128 | public function getPluginType() { |
| 129 | - list($type, ) = $this->getNameParts(); |
|
| 129 | + list($type,) = $this->getNameParts(); |
|
| 130 | 130 | |
| 131 | 131 | return $type; |
| 132 | 132 | } |
@@ -84,7 +84,7 @@ |
||
| 84 | 84 | * @param integer $maturity |
| 85 | 85 | * @param ComponentSource[]|null $sources |
| 86 | 86 | */ |
| 87 | - public function __construct($version, $release, $maturity, $sources=null) { |
|
| 87 | + public function __construct($version, $release, $maturity, $sources = null) { |
|
| 88 | 88 | $this->version = $version; |
| 89 | 89 | $this->release = $release; |
| 90 | 90 | $this->maturity = $maturity; |
@@ -39,9 +39,9 @@ |
||
| 39 | 39 | * @inheritdoc PackageSource |
| 40 | 40 | */ |
| 41 | 41 | public function obtainPackage($tempDirectory, |
| 42 | - ResolvedComponentVersion $resolvedComponentVersion, |
|
| 43 | - Filesystem $filesystem, |
|
| 44 | - LoggerInterface $logger) { |
|
| 42 | + ResolvedComponentVersion $resolvedComponentVersion, |
|
| 43 | + Filesystem $filesystem, |
|
| 44 | + LoggerInterface $logger) { |
|
| 45 | 45 | $version = $resolvedComponentVersion->getVersion(); |
| 46 | 46 | $sources = $version->getSources(); |
| 47 | 47 | |
@@ -42,9 +42,9 @@ |
||
| 42 | 42 | * @inheritdoc PackageSource |
| 43 | 43 | */ |
| 44 | 44 | public function obtainPackage($tempDirectory, |
| 45 | - ResolvedComponentVersion $resolvedComponentVersion, |
|
| 46 | - Filesystem $filesystem, |
|
| 47 | - LoggerInterface $logger) { |
|
| 45 | + ResolvedComponentVersion $resolvedComponentVersion, |
|
| 46 | + Filesystem $filesystem, |
|
| 47 | + LoggerInterface $logger) { |
|
| 48 | 48 | $componentVersion = $resolvedComponentVersion->getVersion(); |
| 49 | 49 | |
| 50 | 50 | $sources = $componentVersion->getSources(); |
@@ -82,9 +82,9 @@ discard block |
||
| 82 | 82 | * @return string |
| 83 | 83 | */ |
| 84 | 84 | protected function getArchiveFilename(Component $component, |
| 85 | - ComponentVersion $version) { |
|
| 85 | + ComponentVersion $version) { |
|
| 86 | 86 | return sprintf(static::ARCHIVE_FILENAME_FORMAT, $component->getName(), |
| 87 | - $version->getVersion()); |
|
| 87 | + $version->getVersion()); |
|
| 88 | 88 | } |
| 89 | 89 | |
| 90 | 90 | /** |
@@ -96,18 +96,18 @@ discard block |
||
| 96 | 96 | * @return string |
| 97 | 97 | */ |
| 98 | 98 | protected function getTargetDirectory(Component $component, |
| 99 | - ComponentVersion $version) { |
|
| 99 | + ComponentVersion $version) { |
|
| 100 | 100 | return sprintf(static::TARGET_DIRECTORY_FORMAT, $component->getName(), |
| 101 | - $version->getVersion()); |
|
| 101 | + $version->getVersion()); |
|
| 102 | 102 | } |
| 103 | 103 | |
| 104 | 104 | /** |
| 105 | 105 | * @inheritdoc PackageSource |
| 106 | 106 | */ |
| 107 | 107 | public function obtainPackage($tempDirectory, |
| 108 | - ResolvedComponentVersion $resolvedComponentVersion, |
|
| 109 | - Filesystem $filesystem, |
|
| 110 | - LoggerInterface $logger) { |
|
| 108 | + ResolvedComponentVersion $resolvedComponentVersion, |
|
| 109 | + Filesystem $filesystem, |
|
| 110 | + LoggerInterface $logger) { |
|
| 111 | 111 | $component = $resolvedComponentVersion->getComponent(); |
| 112 | 112 | $version = $resolvedComponentVersion->getVersion(); |
| 113 | 113 | $sources = $version->getSources(); |
@@ -174,8 +174,8 @@ discard block |
||
| 174 | 174 | * @throws InstallationFailureException |
| 175 | 175 | */ |
| 176 | 176 | protected function trySource($tempDirectory, LoggerInterface $logger, |
| 177 | - Component $component, ComponentVersion $version, |
|
| 178 | - ZipComponentSource $source) { |
|
| 177 | + Component $component, ComponentVersion $version, |
|
| 178 | + ZipComponentSource $source) { |
|
| 179 | 179 | $archiveFilename = $this->platform->joinPaths([ |
| 180 | 180 | $tempDirectory, |
| 181 | 181 | $this->getArchiveFilename($component, $version), |