Skip to content

Commit ffb90bc

Browse files
committed
fix incorrect caching of type InputfieldSelect and InputfieldSelectMultiple
1 parent 558f3df commit ffb90bc

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/Type/Fieldtype/FieldtypeOptions.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ class FieldtypeOptions
2121

2222
public static function type($field)
2323
{
24-
return Cache::type(self::$name, function () use ($field) {
25-
$type = new ObjectType([
24+
$type = Cache::type(self::$name, function () use ($field) {
25+
return new ObjectType([
2626
'name' => self::$name,
2727
'description' => self::$description,
2828
'fields' => [
@@ -52,13 +52,13 @@ public static function type($field)
5252
]
5353
],
5454
]);
55+
});
5556

56-
if (self::isMultiple($field)) {
57-
return Type::listOf($type);
58-
}
57+
if (self::isMultiple($field)) {
58+
return Type::listOf($type);
59+
}
5960

60-
return $type;
61-
});
61+
return $type;
6262
}
6363

6464
public static function inputType($field)

0 commit comments

Comments
 (0)