Skip to content

Commit 2146054

Browse files
tiefenbdadish
authored andcommitted
fix(third-party-fieldtype): allow multiple types to be created by third-party fieldtypes
This change is needed to support multiple SelectExtOption fields with https://github.com/blue-tomato/GraphQLFieldtypeSelectExtOption since this field can have different types.
1 parent 562644e commit 2146054

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Type/Fieldtype/FieldtypeThirdParty.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ class FieldtypeThirdParty
1010
public static function &type($field)
1111
{
1212
$thirdPartyClassName = self::getThirdPartyClassName($field);
13-
$type =& Cache::type($thirdPartyClassName, function () use ($field, $thirdPartyClassName) {
13+
$type =& Cache::type("type--{$field->name}", function () use ($field, $thirdPartyClassName) {
1414
return $thirdPartyClassName::getType($field);
1515
});
1616
return $type;

0 commit comments

Comments
 (0)