@@ -260,7 +260,7 @@ |
||
| 260 | 260 | if ($this->mailLoggingEnabled) { |
| 261 | 261 | $this->logger->info(sprintf('Email sent to %s', 'multiple users'), [ |
| 262 | 262 | 'in' => __METHOD__, |
| 263 | - 'users' => array_reduce($users, function (UserEntity $user) { return $user->getEmail() . ','; }, 'emails: ') |
|
| 263 | + 'users' => array_reduce($users, function(UserEntity $user) { return $user->getEmail() . ','; }, 'emails: ') |
|
| 264 | 264 | ]); |
| 265 | 265 | } |
| 266 | 266 | |
@@ -64,7 +64,7 @@ |
||
| 64 | 64 | } else { |
| 65 | 65 | $quote = in_array(mb_substr((string) $value, 0, 1), ['\'', '"']) ? '\'' : ''; |
| 66 | 66 | $value = !empty($quote) ? trim((string) $value, '\'"') : (string) $value; |
| 67 | - $value = $quote . urlencode($value) . $quote; |
|
| 67 | + $value = $quote . urlencode($value) . $quote; |
|
| 68 | 68 | } |
| 69 | 69 | $lines[] = $key . '=' . $value; |
| 70 | 70 | } |
@@ -178,7 +178,7 @@ |
||
| 178 | 178 | if ($input->isInteractive()) { |
| 179 | 179 | $io->text($this->translator->trans('Beginning user migration...')); |
| 180 | 180 | } |
| 181 | - $userMigrationMaxuid = (int)$this->migrationHelper->getMaxUnMigratedUid(); |
|
| 181 | + $userMigrationMaxuid = (int) $this->migrationHelper->getMaxUnMigratedUid(); |
|
| 182 | 182 | if ($input->isInteractive()) { |
| 183 | 183 | $progressBar = new ProgressBar($output, (int) ceil($count / MigrationHelper::BATCH_LIMIT)); |
| 184 | 184 | $progressBar->start(); |
@@ -111,8 +111,8 @@ |
||
| 111 | 111 | '); |
| 112 | 112 | foreach ($rows as $row) { |
| 113 | 113 | $this->extensionStateMap[$row['name']] = [ |
| 114 | - 'state' => (int)$row['state'], |
|
| 115 | - 'id' => (int)$row['id'], |
|
| 114 | + 'state' => (int) $row['state'], |
|
| 115 | + 'id' => (int) $row['id'], |
|
| 116 | 116 | ]; |
| 117 | 117 | } |
| 118 | 118 | |
@@ -44,7 +44,7 @@ |
||
| 44 | 44 | |
| 45 | 45 | if ('' !== $sessionId) { |
| 46 | 46 | $qb->orWhere('tbl.sesid = :sid') |
| 47 | - ->setParameter('sid', $sessionId); |
|
| 47 | + ->setParameter('sid', $sessionId); |
|
| 48 | 48 | } |
| 49 | 49 | |
| 50 | 50 | $query = $qb->getQuery(); |
@@ -106,7 +106,7 @@ |
||
| 106 | 106 | $res = $qb->execute(); |
| 107 | 107 | foreach ($res->fetchAll() as $row) { |
| 108 | 108 | if (!array_key_exists($row['bundlename'], $fileExtensions)) { |
| 109 | - $this->removeById((int)$row['id']); |
|
| 109 | + $this->removeById((int) $row['id']); |
|
| 110 | 110 | } |
| 111 | 111 | } |
| 112 | 112 | } |
@@ -91,7 +91,7 @@ |
||
| 91 | 91 | $query->getResult(); |
| 92 | 92 | |
| 93 | 93 | // add new block positions |
| 94 | - foreach ((array)$blockOrder as $order => $bid) { |
|
| 94 | + foreach ((array) $blockOrder as $order => $bid) { |
|
| 95 | 95 | $placement = new BlockPlacementEntity(); |
| 96 | 96 | $placement->setPosition($em->getReference('ZikulaBlocksModule:BlockPositionEntity', $position)); |
| 97 | 97 | $placement->setBlock($em->getReference('ZikulaBlocksModule:BlockEntity', $bid)); |
@@ -47,22 +47,22 @@ discard block |
||
| 47 | 47 | |
| 48 | 48 | $pwd = getcwd(); |
| 49 | 49 | if (is_dir($buildDir)) { |
| 50 | - system("rm -rf ${buildDir}"); |
|
| 50 | + system("rm -rf ${builddir}"); |
|
| 51 | 51 | } |
| 52 | 52 | |
| 53 | 53 | // build env |
| 54 | 54 | $filesystem->mkdir($buildDir, 0755); |
| 55 | 55 | $progress->advance(); |
| 56 | 56 | |
| 57 | - $filesystem->mirror($sourceDir, "${buildDir}/${name}"); |
|
| 57 | + $filesystem->mirror($sourceDir, "${builddir}/${name}"); |
|
| 58 | 58 | $progress->advance(); |
| 59 | 59 | |
| 60 | - PurgeVendorsCommand::cleanVendors("${buildDir}/${name}/vendor", $progress); |
|
| 60 | + PurgeVendorsCommand::cleanVendors("${builddir}/${name}/vendor", $progress); |
|
| 61 | 61 | |
| 62 | 62 | $writableArray = [ |
| 63 | - "${buildDir}/${name}/var/cache", |
|
| 64 | - "${buildDir}/${name}/var/log", |
|
| 65 | - "${buildDir}/${name}/public/uploads", |
|
| 63 | + "${builddir}/${name}/var/cache", |
|
| 64 | + "${builddir}/${name}/var/log", |
|
| 65 | + "${builddir}/${name}/public/uploads", |
|
| 66 | 66 | ]; |
| 67 | 67 | $filesystem->chmod($writableArray, 0777); |
| 68 | 68 | $progress->advance(); |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | $zip = new ZipArchive(); |
| 86 | 86 | $fileName = "${name}.zip"; |
| 87 | 87 | if (true !== $zip->open($fileName, ZipArchive::CREATE)) { |
| 88 | - $output->writeln("<error>Error creating ${fileName}</error>"); |
|
| 88 | + $output->writeln("<error>Error creating ${filename}</error>"); |
|
| 89 | 89 | } |
| 90 | 90 | |
| 91 | 91 | foreach ($allFiles as $file) { |
@@ -98,9 +98,9 @@ discard block |
||
| 98 | 98 | |
| 99 | 99 | // build tar |
| 100 | 100 | $fileName = "${name}.tar"; |
| 101 | - system("tar cp ${name} > ${fileName}"); |
|
| 101 | + system("tar cp ${name} > ${filename}"); |
|
| 102 | 102 | $progress->advance(); |
| 103 | - system("gzip ${fileName}"); |
|
| 103 | + system("gzip ${filename}"); |
|
| 104 | 104 | $progress->advance(); |
| 105 | 105 | |
| 106 | 106 | // checksums |
@@ -116,17 +116,17 @@ discard block |
||
| 116 | 116 | -----------------sha1sums----------------- |
| 117 | 117 | ${zipSha1} ${name}.zip |
| 118 | 118 | ${tarSha1} ${name}.tar.gz |
| 119 | -CHECKSUM; |
|
| 119 | +checksum; |
|
| 120 | 120 | file_put_contents("${name}-checksum.txt", $checksum); |
| 121 | 121 | $progress->advance(); |
| 122 | 122 | |
| 123 | 123 | // cleanup |
| 124 | - system("rm -rf ${buildDir} ${name}"); |
|
| 124 | + system("rm -rf ${builddir} ${name}"); |
|
| 125 | 125 | chdir($pwd); |
| 126 | 126 | $progress->advance(); |
| 127 | 127 | $progress->finish(); |
| 128 | 128 | |
| 129 | - $output->writeln("<info>Artifacts built in ${buildDir}/ folder</info>"); |
|
| 129 | + $output->writeln("<info>Artifacts built in ${builddir}/ folder</info>"); |
|
| 130 | 130 | |
| 131 | 131 | return 0; |
| 132 | 132 | } |
@@ -57,7 +57,7 @@ |
||
| 57 | 57 | $requiredDependents = $this->dependencyHelper->getDependentExtensions($extension); |
| 58 | 58 | if (!empty($requiredDependents)) { |
| 59 | 59 | if ($input->isInteractive()) { |
| 60 | - $names = implode(', ', array_map(function (ExtensionEntity $dependent) { |
|
| 60 | + $names = implode(', ', array_map(function(ExtensionEntity $dependent) { |
|
| 61 | 61 | return $dependent->getName(); |
| 62 | 62 | }, $requiredDependents)); |
| 63 | 63 | |