@@ -50,7 +50,7 @@ |
||
| 50 | 50 | |
| 51 | 51 | $command = new UpdateConfigurationCommand(); |
| 52 | 52 | $command->configuration = $request->getContent(); |
| 53 | - $command->UUID = (string)Uuid::uuid4(); |
|
| 53 | + $command->UUID = (string) Uuid::uuid4(); |
|
| 54 | 54 | |
| 55 | 55 | return $this->handleCommand($request, $command); |
| 56 | 56 | } |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | $this->denyAccessUnlessGranted('ROLE_MANAGEMENT'); |
| 54 | 54 | |
| 55 | 55 | $command = new ReplaceWhitelistCommand(); |
| 56 | - $command->UUID = (string)Uuid::uuid4(); |
|
| 56 | + $command->UUID = (string) Uuid::uuid4(); |
|
| 57 | 57 | $command->institutions = $this->getInstitutionsFromBody($request); |
| 58 | 58 | |
| 59 | 59 | return $this->handleCommand($request, $command); |
@@ -64,7 +64,7 @@ discard block |
||
| 64 | 64 | $this->denyAccessUnlessGranted('ROLE_MANAGEMENT'); |
| 65 | 65 | |
| 66 | 66 | $command = new AddToWhitelistCommand(); |
| 67 | - $command->UUID = (string)Uuid::uuid4(); |
|
| 67 | + $command->UUID = (string) Uuid::uuid4(); |
|
| 68 | 68 | $command->institutionsToBeAdded = $this->getInstitutionsFromBody($request); |
| 69 | 69 | |
| 70 | 70 | return $this->handleCommand($request, $command); |
@@ -75,7 +75,7 @@ discard block |
||
| 75 | 75 | $this->denyAccessUnlessGranted('ROLE_MANAGEMENT'); |
| 76 | 76 | |
| 77 | 77 | $command = new RemoveFromWhitelistCommand(); |
| 78 | - $command->UUID = (string)Uuid::uuid4(); |
|
| 78 | + $command->UUID = (string) Uuid::uuid4(); |
|
| 79 | 79 | $command->institutionsToBeRemoved = $this->getInstitutionsFromBody($request); |
| 80 | 80 | |
| 81 | 81 | return $this->handleCommand($request, $command); |
@@ -64,7 +64,7 @@ |
||
| 64 | 64 | $this->assertMayForget(new NameId($payload['name_id']), new Institution($payload['institution'])); |
| 65 | 65 | |
| 66 | 66 | $command = new ForgetIdentityCommand(); |
| 67 | - $command->UUID = (string)Uuid::uuid4(); |
|
| 67 | + $command->UUID = (string) Uuid::uuid4(); |
|
| 68 | 68 | $command->nameId = $payload['name_id']; |
| 69 | 69 | $command->institution = $payload['institution']; |
| 70 | 70 | |
@@ -126,7 +126,7 @@ |
||
| 126 | 126 | $commands = []; |
| 127 | 127 | foreach ($configuration as $institution => $options) { |
| 128 | 128 | $command = new ReconfigureInstitutionConfigurationOptionsCommand(); |
| 129 | - $command->UUID = (string)Uuid::uuid4(); |
|
| 129 | + $command->UUID = (string) Uuid::uuid4(); |
|
| 130 | 130 | $command->institution = $institution; |
| 131 | 131 | $command->useRaLocationsOption = $options['use_ra_locations']; |
| 132 | 132 | $command->showRaaContactInformationOption = $options['show_raa_contact_information']; |
@@ -43,10 +43,10 @@ discard block |
||
| 43 | 43 | WHERE identity_id = :identity_id |
| 44 | 44 | ORDER BY playhead ASC'; |
| 45 | 45 | |
| 46 | - $rows = $this->connection->fetchAllAssociative($sql, ['identity_id' => (string)$identityId]); |
|
| 46 | + $rows = $this->connection->fetchAllAssociative($sql, ['identity_id' => (string) $identityId]); |
|
| 47 | 47 | $messages = array_map(fn(array $row): SensitiveDataMessage => new SensitiveDataMessage( |
| 48 | 48 | $identityId, |
| 49 | - (int)$row['playhead'], |
|
| 49 | + (int) $row['playhead'], |
|
| 50 | 50 | SensitiveData::deserialize(JsonHelper::decode($row['sensitive_data'])), |
| 51 | 51 | ), $rows); |
| 52 | 52 | |
@@ -64,9 +64,9 @@ discard block |
||
| 64 | 64 | foreach ($sensitiveDataMessageStream as $sensitiveDataMessage) { |
| 65 | 65 | /** @var SensitiveDataMessage $sensitiveDataMessage */ |
| 66 | 66 | $this->connection->insert('event_stream_sensitive_data', [ |
| 67 | - 'identity_id' => (string)$sensitiveDataMessage->getIdentityId(), |
|
| 67 | + 'identity_id' => (string) $sensitiveDataMessage->getIdentityId(), |
|
| 68 | 68 | 'playhead' => $sensitiveDataMessage->getPlayhead(), |
| 69 | - 'sensitive_data' => json_encode((object)$sensitiveDataMessage->getSensitiveData()->serialize()), |
|
| 69 | + 'sensitive_data' => json_encode((object) $sensitiveDataMessage->getSensitiveData()->serialize()), |
|
| 70 | 70 | ]); |
| 71 | 71 | } |
| 72 | 72 | $this->connection->commit(); |
@@ -88,9 +88,9 @@ discard block |
||
| 88 | 88 | /** @var SensitiveDataMessage $sensitiveDataMessage */ |
| 89 | 89 | $this->connection->update( |
| 90 | 90 | 'event_stream_sensitive_data', |
| 91 | - ['sensitive_data' => json_encode((object)$sensitiveDataMessage->getSensitiveData()->serialize())], |
|
| 91 | + ['sensitive_data' => json_encode((object) $sensitiveDataMessage->getSensitiveData()->serialize())], |
|
| 92 | 92 | [ |
| 93 | - 'identity_id' => (string)$sensitiveDataMessage->getIdentityId(), |
|
| 93 | + 'identity_id' => (string) $sensitiveDataMessage->getIdentityId(), |
|
| 94 | 94 | 'playhead' => $sensitiveDataMessage->getPlayhead(), |
| 95 | 95 | ], |
| 96 | 96 | ); |
@@ -181,7 +181,7 @@ |
||
| 181 | 181 | 'email' => $this->email, |
| 182 | 182 | 'second_factor_type' => $this->secondFactorType, |
| 183 | 183 | 'second_factor_identifier' => $this->secondFactorIdentifier, |
| 184 | - 'recovery_token_type' => (string)$this->recoveryTokenType, |
|
| 184 | + 'recovery_token_type' => (string) $this->recoveryTokenType, |
|
| 185 | 185 | 'recovery_token_identifier' => $this->recoveryTokenIdentifier, |
| 186 | 186 | 'vetting_type' => $vettingType, |
| 187 | 187 | ]); |
@@ -151,7 +151,7 @@ discard block |
||
| 151 | 151 | ); |
| 152 | 152 | |
| 153 | 153 | $configurationInstitution = new ConfigurationInstitution( |
| 154 | - (string)$identity->getInstitution(), |
|
| 154 | + (string) $identity->getInstitution(), |
|
| 155 | 155 | ); |
| 156 | 156 | |
| 157 | 157 | $tokenCount = $this->institutionConfigurationOptionsService->getMaxNumberOfTokensFor($configurationInstitution); |
@@ -173,7 +173,7 @@ discard block |
||
| 173 | 173 | $this->assertSecondFactorIsAllowedFor(new SecondFactorType('yubikey'), $identity->getInstitution()); |
| 174 | 174 | |
| 175 | 175 | $configurationInstitution = new ConfigurationInstitution( |
| 176 | - (string)$identity->getInstitution(), |
|
| 176 | + (string) $identity->getInstitution(), |
|
| 177 | 177 | ); |
| 178 | 178 | $tokenCount = $this->institutionConfigurationOptionsService->getMaxNumberOfTokensFor($configurationInstitution); |
| 179 | 179 | |
@@ -196,7 +196,7 @@ discard block |
||
| 196 | 196 | $this->assertSecondFactorIsAllowedFor(new SecondFactorType('sms'), $identity->getInstitution()); |
| 197 | 197 | |
| 198 | 198 | $configurationInstitution = new ConfigurationInstitution( |
| 199 | - (string)$identity->getInstitution(), |
|
| 199 | + (string) $identity->getInstitution(), |
|
| 200 | 200 | ); |
| 201 | 201 | |
| 202 | 202 | $tokenCount = $this->institutionConfigurationOptionsService->getMaxNumberOfTokensFor($configurationInstitution); |
@@ -222,7 +222,7 @@ discard block |
||
| 222 | 222 | $this->assertSecondFactorIsAllowedFor(new SecondFactorType($secondFactorType), $identity->getInstitution()); |
| 223 | 223 | |
| 224 | 224 | $configurationInstitution = new ConfigurationInstitution( |
| 225 | - (string)$identity->getInstitution(), |
|
| 225 | + (string) $identity->getInstitution(), |
|
| 226 | 226 | ); |
| 227 | 227 | |
| 228 | 228 | $tokenCount = $this->institutionConfigurationOptionsService->getMaxNumberOfTokensFor($configurationInstitution); |
@@ -247,7 +247,7 @@ discard block |
||
| 247 | 247 | $this->assertSecondFactorIsAllowedFor(new SecondFactorType('u2f'), $identity->getInstitution()); |
| 248 | 248 | |
| 249 | 249 | $configurationInstitution = new ConfigurationInstitution( |
| 250 | - (string)$identity->getInstitution(), |
|
| 250 | + (string) $identity->getInstitution(), |
|
| 251 | 251 | ); |
| 252 | 252 | |
| 253 | 253 | $tokenCount = $this->institutionConfigurationOptionsService->getMaxNumberOfTokensFor($configurationInstitution); |
@@ -409,7 +409,7 @@ discard block |
||
| 409 | 409 | |
| 410 | 410 | // Determine the maximum number of allowed tokens for the institution |
| 411 | 411 | $configurationInstitution = new ConfigurationInstitution( |
| 412 | - (string)$targetIdentity->getInstitution(), |
|
| 412 | + (string) $targetIdentity->getInstitution(), |
|
| 413 | 413 | ); |
| 414 | 414 | $tokenCount = $this->institutionConfigurationOptionsService->getMaxNumberOfTokensFor($configurationInstitution); |
| 415 | 415 | |
@@ -486,7 +486,7 @@ discard block |
||
| 486 | 486 | { |
| 487 | 487 | if (!$this->configurableSettings->isSupportedLocale($locale)) { |
| 488 | 488 | throw new UnsupportedLocaleException( |
| 489 | - sprintf('Given locale "%s" is not a supported locale', (string)$locale), |
|
| 489 | + sprintf('Given locale "%s" is not a supported locale', (string) $locale), |
|
| 490 | 490 | ); |
| 491 | 491 | } |
| 492 | 492 | } |
@@ -511,7 +511,7 @@ discard block |
||
| 511 | 511 | public function assertSelfAssertedTokensEnabled(Institution $institution): void |
| 512 | 512 | { |
| 513 | 513 | $configurationInstitution = new ConfigurationInstitution( |
| 514 | - (string)$institution, |
|
| 514 | + (string) $institution, |
|
| 515 | 515 | ); |
| 516 | 516 | |
| 517 | 517 | $institutionConfiguration = $this->institutionConfigurationOptionsService |
@@ -520,7 +520,7 @@ discard block |
||
| 520 | 520 | throw new RuntimeException( |
| 521 | 521 | sprintf( |
| 522 | 522 | 'Registration of self-asserted tokens is not allowed for this institution "%s".', |
| 523 | - (string)$institution, |
|
| 523 | + (string) $institution, |
|
| 524 | 524 | ), |
| 525 | 525 | ); |
| 526 | 526 | } |
@@ -532,7 +532,7 @@ discard block |
||
| 532 | 532 | private function emailVerificationIsRequired(IdentityApi $identity): bool |
| 533 | 533 | { |
| 534 | 534 | $institution = new ConfigurationInstitution( |
| 535 | - (string)$identity->getInstitution(), |
|
| 535 | + (string) $identity->getInstitution(), |
|
| 536 | 536 | ); |
| 537 | 537 | |
| 538 | 538 | $configuration = $this->institutionConfigurationOptionsService |
@@ -158,7 +158,7 @@ discard block |
||
| 158 | 158 | 'commonName' => $commonName, |
| 159 | 159 | 'emailAddress' => $email, |
| 160 | 160 | 'registrationCode' => $registrationCode, |
| 161 | - 'expirationDate' => (string)$expirationDate, |
|
| 161 | + 'expirationDate' => (string) $expirationDate, |
|
| 162 | 162 | 'ras' => $ras, |
| 163 | 163 | 'selfServiceUrl' => $this->selfServiceUrl, |
| 164 | 164 | ]; |
@@ -208,7 +208,7 @@ discard block |
||
| 208 | 208 | 'commonName' => $commonName, |
| 209 | 209 | 'emailAddress' => $email, |
| 210 | 210 | 'registrationCode' => $registrationCode, |
| 211 | - 'expirationDate' => (string)$expirationDate, |
|
| 211 | + 'expirationDate' => (string) $expirationDate, |
|
| 212 | 212 | 'raLocations' => $raLocations, |
| 213 | 213 | 'selfServiceUrl' => $this->selfServiceUrl, |
| 214 | 214 | ]; |
@@ -61,7 +61,7 @@ |
||
| 61 | 61 | |
| 62 | 62 | public function findBy(Institution $institution): VettingTypeHintEntity |
| 63 | 63 | { |
| 64 | - $result = $this->repository->find((string)$institution); |
|
| 64 | + $result = $this->repository->find((string) $institution); |
|
| 65 | 65 | if (!$result) { |
| 66 | 66 | throw new NotFoundException(sprintf('Vetting type hint not found for institution %s', $institution)); |
| 67 | 67 | } |