Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
product_with_multiple_options_rollback.php
Go to the documentation of this file.
1 <?php
7 require __DIR__ . '/../../../Magento/Catalog/_files/multiple_products_rollback.php';
8 
11 
12 $registry->unregister('isSecureArea');
13 $registry->register('isSecureArea', true);
14 
15 try {
16  $product = $productRepository->get('bundle-product');
18 } catch (\Magento\Framework\Exception\NoSuchEntityException $exception) {
19  //Product already removed
20 }
21 
22 $registry->unregister('isSecureArea');
23 $registry->register('isSecureArea', false);
defined('TESTS_BP')||define('TESTS_BP' __DIR__
Definition: _bootstrap.php:60