]> _ Git - cubist_cms-back.git/commitdiff
#2843
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Thu, 27 Jun 2019 18:29:02 +0000 (20:29 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Thu, 27 Jun 2019 18:29:02 +0000 (20:29 +0200)
src/app/Magic/Fields/Field.php

index 40dfbc43fa03b33fd4109f6c57111f929e45731b..4c9ca0ef6e1b76947f3c656763bb1cb361ee044d 100644 (file)
@@ -84,7 +84,7 @@ class Field implements \ArrayAccess
     protected static function _getClass($type)
     {
         $type = Str::studly($type);
-        if (class_exists($type)) {
+        if (class_exists($type) && is_subclass_of($type, self::class)) {
             return $type;
         }
         if (class_exists(__NAMESPACE__ . '\\' . $type)) {