Update to Drupal 8.1.0. For more information, see https://www.drupal.org/drupal-8.1.0-release-notes
This commit is contained in:
parent
b11a755ba8
commit
c0a0d5a94c
6920 changed files with 64395 additions and 57312 deletions
|
@ -66,12 +66,16 @@ class AnnotationDirectoryLoader extends AnnotationFileLoader
|
|||
*/
|
||||
public function supports($resource, $type = null)
|
||||
{
|
||||
if (!is_string($resource)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
try {
|
||||
$path = $this->locator->locate($resource);
|
||||
} catch (\Exception $e) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return is_string($resource) && is_dir($path) && (!$type || 'annotation' === $type);
|
||||
return is_dir($path) && (!$type || 'annotation' === $type);
|
||||
}
|
||||
}
|
||||
|
|
Reference in a new issue