Skip to content

Commit c147c60

Browse files
author
Oleksandr Gorkun
committed
MAGETWO-96975: Remove __sleep and __wakeup from code
1 parent bfa9514 commit c147c60

File tree

27 files changed

+54
-54
lines changed

27 files changed

+54
-54
lines changed

app/code/Magento/Authorization/Model/Role.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ public function __construct(
5858
*/
5959
public function __sleep()
6060
{
61-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
61+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
6262

6363
$properties = parent::__sleep();
6464
return array_diff($properties, ['_resource', '_resourceCollection']);
@@ -72,7 +72,7 @@ public function __sleep()
7272
*/
7373
public function __wakeup()
7474
{
75-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
75+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
7676

7777
parent::__wakeup();
7878
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();

app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -851,7 +851,7 @@ public function afterDelete()
851851
*/
852852
public function __sleep()
853853
{
854-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
854+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
855855

856856
$this->unsetData('entity_type');
857857
return array_diff(
@@ -869,7 +869,7 @@ public function __sleep()
869869
*/
870870
public function __wakeup()
871871
{
872-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
872+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
873873

874874
parent::__wakeup();
875875
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();

app/code/Magento/Config/Model/Config/Backend/Encrypted.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public function __construct(
5656
*/
5757
public function __sleep()
5858
{
59-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
59+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
6060

6161
$properties = parent::__sleep();
6262
return array_diff($properties, ['_encryptor']);
@@ -72,7 +72,7 @@ public function __sleep()
7272
*/
7373
public function __wakeup()
7474
{
75-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
75+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
7676

7777
parent::__wakeup();
7878
$this->_encryptor = \Magento\Framework\App\ObjectManager::getInstance()->get(

app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ public function setProductId($value)
271271
*/
272272
public function __sleep()
273273
{
274-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
274+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
275275

276276
return array_diff(
277277
parent::__sleep(),
@@ -287,7 +287,7 @@ public function __sleep()
287287
*/
288288
public function __wakeup()
289289
{
290-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
290+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
291291

292292
parent::__wakeup();
293293
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();

app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ protected function getIncludedOptions(array $usedProducts, AbstractAttribute $pr
364364
*/
365365
public function __sleep()
366366
{
367-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
367+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
368368

369369
return array_diff(
370370
parent::__sleep(),
@@ -388,7 +388,7 @@ public function __sleep()
388388
*/
389389
public function __wakeup()
390390
{
391-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
391+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
392392

393393
parent::__wakeup();
394394
$objectManager = ObjectManager::getInstance();

app/code/Magento/Customer/Model/Attribute.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ public function canBeFilterableInGrid()
208208
*/
209209
public function __sleep()
210210
{
211-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
211+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
212212

213213
$this->unsetData('entity_type');
214214
return array_diff(
@@ -225,7 +225,7 @@ public function __sleep()
225225
*/
226226
public function __wakeup()
227227
{
228-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
228+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
229229

230230
parent::__wakeup();
231231
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();

app/code/Magento/Eav/Model/Entity/Attribute.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -502,7 +502,7 @@ public function getIdentities()
502502
*/
503503
public function __sleep()
504504
{
505-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
505+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
506506

507507
$this->unsetData('attribute_set_info');
508508
return array_diff(
@@ -520,7 +520,7 @@ public function __sleep()
520520
*/
521521
public function __wakeup()
522522
{
523-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
523+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
524524

525525
parent::__wakeup();
526526
$objectManager = ObjectManager::getInstance();

app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1410,7 +1410,7 @@ public function setExtensionAttributes(\Magento\Eav\Api\Data\AttributeExtensionI
14101410
*/
14111411
public function __sleep()
14121412
{
1413-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
1413+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
14141414

14151415
return array_diff(
14161416
parent::__sleep(),
@@ -1440,7 +1440,7 @@ public function __sleep()
14401440
*/
14411441
public function __wakeup()
14421442
{
1443-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
1443+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
14441444

14451445
parent::__wakeup();
14461446
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();

app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -731,7 +731,7 @@ public function getValidAttributeIds($attributeIds)
731731
*/
732732
public function __sleep()
733733
{
734-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
734+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
735735

736736
$properties = parent::__sleep();
737737
$properties = array_diff($properties, ['_storeManager']);
@@ -749,7 +749,7 @@ public function __sleep()
749749
*/
750750
public function __wakeup()
751751
{
752-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
752+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
753753

754754
parent::__wakeup();
755755
$this->_storeManager = \Magento\Framework\App\ObjectManager::getInstance()

app/code/Magento/Store/Model/Store.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -429,7 +429,7 @@ public function __construct(
429429
*/
430430
public function __sleep()
431431
{
432-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
432+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
433433

434434
$properties = parent::__sleep();
435435
$properties = array_diff($properties, ['_coreFileStorageDatabase', '_config']);
@@ -446,7 +446,7 @@ public function __sleep()
446446
*/
447447
public function __wakeup()
448448
{
449-
//trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
449+
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
450450

451451
parent::__wakeup();
452452
$this->_coreFileStorageDatabase = ObjectManager::getInstance()

0 commit comments

Comments
 (0)