public function retrieveProductAttributeByAttribute(ProductInterface $product, Attribute $attribute)
    {
        foreach ($product->getProductAttributes() as $productAttribute) {
            if ($productAttribute->getAttribute()->getId() === $attribute->getId()) {
                return $productAttribute;
            }
        }

        return null;
    }