Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
select_attribute_rollback.php
Go to the documentation of this file.
1 <?php
8 
9 $registry = $objectManager->get(\Magento\Framework\Registry::class);
10 $registry->unregister('isSecureArea');
11 $registry->register('isSecureArea', true);
14  \Magento\Catalog\Model\ResourceModel\Eav\Attribute::class
15 );
16 $attribute->load('select_attribute', 'attribute_code');
17 $attribute->delete();
18 
19 $registry->unregister('isSecureArea');
20 $registry->register('isSecureArea', false);