Skip to content

Commit

Permalink
Merge pull request #33 from mogilvie/patch-1
Browse files Browse the repository at this point in the history
Update UpdateSchemaCommand.php
  • Loading branch information
RamyHakam authored Apr 24, 2024
2 parents 466e821 + edae792 commit f228a52
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/Command/UpdateSchemaCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,11 @@ protected function execute(InputInterface $input, OutputInterface $output): int
$repo = $this->entityManager->getRepository(Tenant::class);

if (null !== $tenantId) {
// Get tenant db name passed as an option.
$tenants = $repo->findBy(['dbName' => $singleDbName]);
} elseif (null !== $singleDbName) {
// Get tenant using the tenant id.
$tenants = $repo->findBy(['id' => $tenantId]);
} elseif (null !== $singleDbName) {
// Get tenant using database name.
$tenants = $repo->findBy(['dbName' => $singleDbName]);
} else {
// Get all tenants
$tenants = $repo->findAll();
Expand Down

0 comments on commit f228a52

Please sign in to comment.