protected function hasNotification(SaleInterface $sale, $type, $number)
    {
        foreach ($sale->getNotifications() as $n) {
            if ($n->getType() !== $type) {
                continue;
            }

            if ($n->hasData('shipment') && $n->getData('shipment') === $number) {
                return true;
            }
        }

        return false;
    }