protected function getRelatedCartItem($product)
    {
        $cartItemIdList =  $this->facade->getRequest()->getSession()->get(
            $this->getSessionVarName(),
            array()
        );

        if (isset($cartItemIdList[$product->getId()])) {
            $cartItemId = $cartItemIdList[$product->getId()];

            if ($cartItemId == self::ADD_TO_CART_IN_PROCESS) {
                return self::ADD_TO_CART_IN_PROCESS;
            } elseif (null !== $cartItem = CartItemQuery::create()->findPk($cartItemId)) {
                return $cartItem;
            }
        } else {
            // Maybe the product we're offering is already in the cart ? Search it.
            $cartItems = $this->facade->getCart()->getCartItems();

            /** @var CartItem $cartItem */
            foreach ($cartItems as $cartItem) {
                if ($cartItem->getProduct()->getId() == $this->offeredProductId) {
                    // We found the product. Store its cart item as the free product container.
                    $this->setRelatedCartItem($product, $cartItem->getId());

                    return $cartItem;
                }
            }
        }

        return false;
    }