Skip to content
Snippets Groups Projects
Commit 416099f9 authored by Jacob Rockowitz's avatar Jacob Rockowitz Committed by Jacob Rockowitz
Browse files

Issue #3361271 by jrockowitz: Warning: Trying to access array offset on value...

Issue #3361271 by jrockowitz: Warning: Trying to access array offset on value of type bool in Drupal\schemadotorg\SchemaDotOrgSchemaTypeManager->hasProperty() - line 666
parent 899bc09e
No related branches found
No related tags found
No related merge requests found
......@@ -657,7 +657,7 @@ class SchemaDotOrgSchemaTypeManager implements SchemaDotOrgSchemaTypeManagerInte
*/
public function hasProperty(string $type, string $property): bool {
$type_definition = $this->getType($type);
return (str_contains($type_definition['properties'], '/' . $property));
return ($type_definition && str_contains($type_definition['properties'], '/' . $property));
}
/**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment