소스 검색

[Validator] Updated ContraintViolationList ArrayAccess setter to check equivalence to null instead of using is_null

Mark Challoner 14 년 전
부모
커밋
1adbb763cb
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/Symfony/Component/Validator/ConstraintViolationList.php

+ 1 - 1
src/Symfony/Component/Validator/ConstraintViolationList.php

@@ -97,7 +97,7 @@ EOF;
      */
     public function offsetSet($offset, $value)
     {
-        if (is_null($offset)) {
+        if (null === $offset) {
             $this->violations[] = $value;
         } else {
             $this->violations[$offset] = $value;