소스 검색

Fix for issue #343
Check avalibility of class on SoftDeleteable Annotation driver

Tom0 13 년 전
부모
커밋
b2d358f354
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      lib/Gedmo/SoftDeleteable/Mapping/Driver/Annotation.php

+ 1 - 1
lib/Gedmo/SoftDeleteable/Mapping/Driver/Annotation.php

@@ -61,7 +61,7 @@ class Annotation implements AnnotationDriverInterface
     {
         $class = $meta->getReflectionClass();
         // class annotations
-        if ($annot = $this->reader->getClassAnnotation($class, self::SOFT_DELETEABLE)) {
+        if ($class !== null && $annot = $this->reader->getClassAnnotation($class, self::SOFT_DELETEABLE)) {
             $config['softDeleteable'] = true;
 
             Validator::validateField($meta, $annot->fieldName);