From d758b29a7993d2653c610dee9455490f9b896e84 Mon Sep 17 00:00:00 2001 From: Sven Reichel Date: Thu, 13 Dec 2018 22:46:55 +0100 Subject: [PATCH] Added int as input type Fixes phpstan where 1st parameter is entity_id and 2nd $product->getId() 115 Parameter #2 $value of method Magento\Catalog\Model\AbstractModel::loadByAttribute() expects array|string|null, int|null given. --- app/code/Magento/Catalog/Model/AbstractModel.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/Magento/Catalog/Model/AbstractModel.php b/app/code/Magento/Catalog/Model/AbstractModel.php index 78a49cd1e8b14..99b07978732ed 100644 --- a/app/code/Magento/Catalog/Model/AbstractModel.php +++ b/app/code/Magento/Catalog/Model/AbstractModel.php @@ -235,7 +235,7 @@ public function getResourceCollection() * Load entity by attribute * * @param \Magento\Eav\Model\Entity\Attribute\AttributeInterface|integer|string|array $attribute - * @param null|string|array $value + * @param null|string|int|array $value * @param string $additionalAttributes * @return bool|\Magento\Catalog\Model\AbstractModel */