mirror of
				https://github.com/yiisoft/yii2.git
				synced 2025-11-04 06:37:55 +08:00 
			
		
		
		
	Fix IsOneOfAssert constructor parameter type declaration.
This commit is contained in:
		@ -19,7 +19,7 @@ class IsOneOfAssert extends \PHPUnit\Framework\Constraint\Constraint
 | 
				
			|||||||
     */
 | 
					     */
 | 
				
			||||||
    private $allowedValues = [];
 | 
					    private $allowedValues = [];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    public function __construct($allowedValues)
 | 
					    public function __construct(array $allowedValues)
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
        $this->allowedValues = $allowedValues;
 | 
					        $this->allowedValues = $allowedValues;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
@ -42,6 +42,6 @@ class IsOneOfAssert extends \PHPUnit\Framework\Constraint\Constraint
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    protected function matches($other): bool
 | 
					    protected function matches($other): bool
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
        return in_array($other, $this->allowedValues);
 | 
					        return in_array($other, $this->allowedValues, false);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user