Automattic\WooCommerce\Vendor\GraphQL\Utils
BreakingChangesFinder::getDirectiveMapForSchema
Method of the class: BreakingChangesFinder{}
No Hooks.
Returns
array<string, Directive>.
Usage
$result = BreakingChangesFinder::getDirectiveMapForSchema( $schema ): array;
- $schema(Schema) (required)
- .
BreakingChangesFinder::getDirectiveMapForSchema() BreakingChangesFinder::getDirectiveMapForSchema code WC 11.1.2
private static function getDirectiveMapForSchema(Schema $schema): array
{
$directives = [];
foreach ($schema->getDirectives() as $directive) {
$directives[$directive->name] = $directive;
}
return $directives;
}