Completed
Pull Request — master (#44)
by Alex
03:25
created
src/Edm/Validation/Internal/InterfaceValidator/VisitorOfINamedElement.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
     protected function VisitT($item, array &$followup, array &$references): iterable
14 14
     {
15 15
         assert($item instanceof INamedElement);
16
-        return $item->getName() != null ? null : [ InterfaceValidator::CreatePropertyMustNotBeNullError($item, 'Name') ];
16
+        return $item->getName() != null ? null : [InterfaceValidator::CreatePropertyMustNotBeNullError($item, 'Name')];
17 17
     }
18 18
 
19 19
     public function forType(): string
Please login to merge, or discard this patch.
src/Edm/Validation/Internal/InterfaceValidator/VisitorOfIType.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@
 block discarded – undo
59 59
                         break;
60 60
                 }
61 61
 
62
-        return $typeKindError != null ? [$typeKindError ] : null;
62
+        return $typeKindError != null ? [$typeKindError] : null;
63 63
     }
64 64
 
65 65
     public function forType(): string
Please login to merge, or discard this patch.
src/Edm/Validation/Internal/InterfaceValidator/VisitorOfIExpression.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
                     $expressionKindError = InterfaceValidator::CheckForInterfaceKindValueMismatchError($expression, $expression->getExpressionKind(), 'ExpressionKind', IEnumMemberReferenceExpression::class);
125 125
                     break;
126 126
 
127
-                case ExpressionKind::If():
127
+                case ExpressionKind::If ():
128 128
                     $expressionKindError = InterfaceValidator::CheckForInterfaceKindValueMismatchError($expression, $expression->getExpressionKind(), 'ExpressionKind', IIfExpression::class);
129 129
                     break;
130 130
 
@@ -154,7 +154,7 @@  discard block
 block discarded – undo
154 154
             }
155 155
         }
156 156
 
157
-        return $expressionKindError != null ? [ $expressionKindError ] : null;
157
+        return $expressionKindError != null ? [$expressionKindError] : null;
158 158
     }
159 159
 
160 160
     public function forType(): string
Please login to merge, or discard this patch.
Validation/Internal/InterfaceValidator/VisitorOfIEntityReferenceType.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@
 block discarded – undo
17 17
             $references[] = $type->getEntityType();
18 18
             return null;
19 19
         } else {
20
-            return [ InterfaceValidator::CreatePropertyMustNotBeNullError($type, 'EntityType') ];
20
+            return [InterfaceValidator::CreatePropertyMustNotBeNullError($type, 'EntityType')];
21 21
         }
22 22
     }
23 23
 
Please login to merge, or discard this patch.
StructuralPropertyInvalidPropertyTypeConcurrencyMode.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -31,8 +31,7 @@
 block discarded – undo
31 31
                 StringConst::EdmModel_Validator_Semantic_InvalidPropertyTypeConcurrencyMode(
32 32
                     (
33 33
                         $property->getType()->IsCollection() ?
34
-                        EdmConstants::Type_Collection :
35
-                        $property->getType()->TypeKind()->getKey()
34
+                        EdmConstants::Type_Collection : $property->getType()->TypeKind()->getKey()
36 35
                     )
37 36
                 )
38 37
             );
Please login to merge, or discard this patch.
IFunctionImport/FunctionImportUnsupportedReturnTypeAfterV1.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,8 +23,7 @@
 block discarded – undo
23 23
         assert($functionImport instanceof IFunctionImport);
24 24
         if ($functionImport->getReturnType() != null) {
25 25
             $elementType = $functionImport->getReturnType()->IsCollection() ?
26
-                $functionImport->getReturnType()->AsCollection()->ElementType() :
27
-                $functionImport->getReturnType();
26
+                $functionImport->getReturnType()->AsCollection()->ElementType() : $functionImport->getReturnType();
28 27
             if (
29 28
                 !$elementType->IsPrimitive() &&
30 29
                 !$elementType->IsEntity() &&
Please login to merge, or discard this patch.
IFunctionImport/FunctionImportEntityTypeDoesNotMatchEntitySet.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -26,8 +26,7 @@
 block discarded – undo
26 26
         assert($functionImport instanceof IFunctionImport);
27 27
         if ($functionImport->getEntitySet() != null && $functionImport->getReturnType() != null) {
28 28
             $elementType = $functionImport->getReturnType()->IsCollection() ?
29
-                $functionImport->getReturnType()->AsCollection()->ElementType() :
30
-                $functionImport->getReturnType();
29
+                $functionImport->getReturnType()->AsCollection()->ElementType() : $functionImport->getReturnType();
31 30
             if ($elementType->IsEntity()) {
32 31
                 $returnedEntityType = $elementType->AsEntity()->EntityDefinition();
33 32
 
Please login to merge, or discard this patch.
ImmediateValueAnnotationElementAnnotationHasNameAndNamespace.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,8 +36,7 @@
 block discarded – undo
36 36
                     ) ?? false
37 37
             )) {
38 38
                 $error = null;
39
-                if (!
40
-                ValidationHelper::ValidateValueCanBeWrittenAsXmlElementAnnotation(
39
+                if (!ValidationHelper::ValidateValueCanBeWrittenAsXmlElementAnnotation(
41 40
                     $stringValue,
42 41
                     $annotation->getNamespaceUri(),
43 42
                     $annotation->getName(),
Please login to merge, or discard this patch.
IDirectValueAnnotation/DirectValueAnnotationHasXmlSerializableName.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
 
38 38
             // Note: this check can be done without the try/catch block, but we need XmlConvert.IsStartNCNameChar and XmlConvert.IsNCNameChar, which are not available in 3.5.
39 39
             if (!XmlConvert::VerifyNCName($annotation->getName())) {
40
-                $value         = $annotation->getValue() ;
40
+                $value         = $annotation->getValue();
41 41
                 $errorLocation = ($value === null || !($value instanceof IValue)) ? null : $value->Location();
42 42
                 $context->AddRawError(new EdmError($errorLocation, EdmErrorCode::InvalidName(), StringConst::EdmModel_Validator_Syntactic_EdmModel_NameIsNotAllowed($annotation->getName())));
43 43
             }
Please login to merge, or discard this patch.