Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / vendor / symfony / validator / Constraints / ImageValidator.php
index 0b3122bbc4e5889e8f72b71846cae8905d738c2f..4b6a6f3b20c6a4e6439d58d4d9f8d415a09342a2 100644 (file)
@@ -34,11 +34,11 @@ class ImageValidator extends FileValidator
             throw new UnexpectedTypeException($constraint, __NAMESPACE__.'\Image');
         }
 
-        $violations = count($this->context->getViolations());
+        $violations = \count($this->context->getViolations());
 
         parent::validate($value, $constraint);
 
-        $failed = count($this->context->getViolations()) !== $violations;
+        $failed = \count($this->context->getViolations()) !== $violations;
 
         if ($failed || null === $value || '' === $value) {
             return;
@@ -217,7 +217,7 @@ class ImageValidator extends FileValidator
         }
 
         if ($constraint->detectCorrupted) {
-            if (!function_exists('imagecreatefromstring')) {
+            if (!\function_exists('imagecreatefromstring')) {
                 throw new RuntimeException('Corrupted images detection requires installed and enabled GD extension');
             }