@@ -89,9 +89,9 @@ |
||
| 89 | 89 | return; |
| 90 | 90 | } |
| 91 | 91 | $command = new ForgetIdentityCommand(); |
| 92 | - $command->UUID = (string)Uuid::uuid4(); |
|
| 92 | + $command->UUID = (string) Uuid::uuid4(); |
|
| 93 | 93 | $command->nameId = $collabPersonId; |
| 94 | - $command->institution = (string)$user->institution; |
|
| 94 | + $command->institution = (string) $user->institution; |
|
| 95 | 95 | $this->logger->debug('Processing the ForgetIdentityCommand'); |
| 96 | 96 | $this->pipeline->process($command); |
| 97 | 97 | } |
@@ -33,7 +33,7 @@ |
||
| 33 | 33 | ->scalarNode('http_basic_realm') |
| 34 | 34 | ->defaultValue('Secure Gateway API') |
| 35 | 35 | ->validate() |
| 36 | - ->ifTrue(function ($realm) { |
|
| 36 | + ->ifTrue(function($realm) { |
|
| 37 | 37 | return !is_string($realm) || empty($realm); |
| 38 | 38 | }) |
| 39 | 39 | ->thenInvalid("Invalid HTTP Basic realm '%s'. Must be string and non-empty.") |
@@ -43,7 +43,7 @@ |
||
| 43 | 43 | throw new RuntimeException(sprintf('Unknown order by column "%s"', $query->orderBy)); |
| 44 | 44 | } |
| 45 | 45 | |
| 46 | - $orderBy = 'rl.'.$query->orderBy; |
|
| 46 | + $orderBy = 'rl.' . $query->orderBy; |
|
| 47 | 47 | $orderDirection = $query->orderDirection === 'asc' ? 'ASC' : 'DESC'; |
| 48 | 48 | |
| 49 | 49 | return $this->getEntityManager()->createQueryBuilder() |
@@ -107,7 +107,7 @@ discard block |
||
| 107 | 107 | $entityManager = $this->getEntityManager(); |
| 108 | 108 | |
| 109 | 109 | $entityManager->createQuery( |
| 110 | - 'DELETE '.InstitutionAuthorization::class.' ia |
|
| 110 | + 'DELETE ' . InstitutionAuthorization::class . ' ia |
|
| 111 | 111 | WHERE ia.institution = :institution' |
| 112 | 112 | ) |
| 113 | 113 | ->setParameter('institution', $institution->getInstitution()) |
@@ -161,7 +161,7 @@ discard block |
||
| 161 | 161 | private function clearOldAuthorizations(EntityManager $entityManager, Institution $institution, InstitutionRole $role) |
| 162 | 162 | { |
| 163 | 163 | $entityManager->createQuery( |
| 164 | - 'DELETE '.InstitutionAuthorization::class.' ia |
|
| 164 | + 'DELETE ' . InstitutionAuthorization::class . ' ia |
|
| 165 | 165 | WHERE ia.institutionRole = :role AND ia.institution = :institution' |
| 166 | 166 | ) |
| 167 | 167 | ->setParameter('role', $role) |
@@ -46,7 +46,7 @@ |
||
| 46 | 46 | |
| 47 | 47 | public function getAllowedSecondFactorListFor(Institution $institution) |
| 48 | 48 | { |
| 49 | - $allowedSecondFactors = array_map(function (AllowedSecondFactor $allowedSecondFactor) { |
|
| 49 | + $allowedSecondFactors = array_map(function(AllowedSecondFactor $allowedSecondFactor) { |
|
| 50 | 50 | return $allowedSecondFactor->secondFactorType; |
| 51 | 51 | }, $this->allowedSecondFactorRepository->getAllowedSecondFactorsFor($institution)); |
| 52 | 52 | |
@@ -43,7 +43,7 @@ |
||
| 43 | 43 | // Else filter on institutions we are allowed to manage |
| 44 | 44 | $values = []; |
| 45 | 45 | foreach ($authorizationContext->getInstitutions() as $institution) { |
| 46 | - $values[] = (string)$institution; |
|
| 46 | + $values[] = (string) $institution; |
|
| 47 | 47 | } |
| 48 | 48 | |
| 49 | 49 | $parameter = $this->getParameterName($authorizationAlias, 'institutions'); |
@@ -194,14 +194,14 @@ |
||
| 194 | 194 | |
| 195 | 195 | private function findInstitutionConfiguration(Identity $identity): ?InstitutionConfigurationOptions |
| 196 | 196 | { |
| 197 | - $institution = new Institution((string)$identity->institution); |
|
| 197 | + $institution = new Institution((string) $identity->institution); |
|
| 198 | 198 | return $this->institutionConfigurationService |
| 199 | 199 | ->findInstitutionConfigurationOptionsFor($institution); |
| 200 | 200 | } |
| 201 | 201 | |
| 202 | 202 | private function findIdentity(IdentityId $identityId): ?Identity |
| 203 | 203 | { |
| 204 | - return $this->identityService->find((string)$identityId); |
|
| 204 | + return $this->identityService->find((string) $identityId); |
|
| 205 | 205 | } |
| 206 | 206 | |
| 207 | 207 | private function deny(string $errorMessage): AuthorizationDecision |
@@ -80,7 +80,7 @@ discard block |
||
| 80 | 80 | */ |
| 81 | 81 | public function buildInstitutionAuthorizationContext(IdentityId $actorId, InstitutionRole $role) |
| 82 | 82 | { |
| 83 | - $identity = $this->identityService->find((string)$actorId); |
|
| 83 | + $identity = $this->identityService->find((string) $actorId); |
|
| 84 | 84 | |
| 85 | 85 | if (!$identity) { |
| 86 | 86 | throw new InvalidArgumentException('The provided id is not associated with any known identity'); |
@@ -93,7 +93,7 @@ discard block |
||
| 93 | 93 | $institutions = new InstitutionCollection(); |
| 94 | 94 | $configuredInstitutions = $this->institutionRepository->findAll(); |
| 95 | 95 | foreach ($configuredInstitutions as $institution) { |
| 96 | - $institutions->add(new Institution((string)$institution->institution)); |
|
| 96 | + $institutions->add(new Institution((string) $institution->institution)); |
|
| 97 | 97 | } |
| 98 | 98 | } elseif ($role->getType() === InstitutionRole::ROLE_SELECT_RAA) { |
| 99 | 99 | // When building an auth context based on the select raa role, we use another query to retrieve the correct |
@@ -15,7 +15,7 @@ |
||
| 15 | 15 | */ |
| 16 | 16 | public function up(Schema $schema): void |
| 17 | 17 | { |
| 18 | - $this->addSql('ALTER TABLE event_stream CHANGE payload payload LONGTEXT NOT NULL'); } |
|
| 18 | + $this->addSql('ALTER TABLE event_stream CHANGE payload payload LONGTEXT NOT NULL'); } |
|
| 19 | 19 | |
| 20 | 20 | /** |
| 21 | 21 | * @param Schema $schema |