|
6 | 6 |
|
7 | 7 | use Ardenexal\FHIRTools\Component\Metadata\Attribute\Validation\FHIRPathInvariant; |
8 | 8 | use Ardenexal\FHIRTools\Component\Metadata\Attribute\Validation\FHIRValueSetBinding; |
9 | | -use Ardenexal\FHIRTools\Component\Validation\FHIRValidationService; |
10 | 9 | use Ardenexal\FHIRTools\Component\Models\R4\DataType\IssueSeverityType as R4IssueSeverityType; |
11 | 10 | use Ardenexal\FHIRTools\Component\Models\R4\DataType\IssueTypeType as R4IssueTypeType; |
12 | 11 | use Ardenexal\FHIRTools\Component\Models\R4\Resource\OperationOutcome\OperationOutcomeIssue as R4Issue; |
@@ -42,9 +41,7 @@ public function toOperationOutcome( |
42 | 41 | 'R4' => $this->buildR4($report->violations), |
43 | 42 | 'R4B' => $this->buildR4B($report->violations), |
44 | 43 | 'R5' => $this->buildR5($report->violations), |
45 | | - default => throw new \InvalidArgumentException( |
46 | | - sprintf('Unsupported FHIR version "%s". Supported values: R4, R4B, R5.', $fhirVersion), |
47 | | - ), |
| 44 | + default => throw new \InvalidArgumentException(sprintf('Unsupported FHIR version "%s". Supported values: R4, R4B, R5.', $fhirVersion)), |
48 | 45 | }; |
49 | 46 | } |
50 | 47 |
|
@@ -116,8 +113,8 @@ private function mapSeverity(string $severity): string |
116 | 113 |
|
117 | 114 | private function mapIssueType(FHIRValidationViolation $violation): string |
118 | 115 | { |
119 | | - if ($violation->code === FHIRViolationCode::EVAL_ERROR |
120 | | - || $violation->code === FHIRViolationCode::UNCHECKED_BINDING |
| 116 | + if ($violation->code === FHIRViolationCode::EVAL_ERROR |
| 117 | + || $violation->code === FHIRViolationCode::UNCHECKED_BINDING |
121 | 118 | || $violation->constraintClass === FHIRValidationService::class) { |
122 | 119 | return 'not-supported'; |
123 | 120 | } |
|
0 commit comments