Created
June 17, 2019 18:52
-
-
Save kazeno/f943337df1c7e8d6415e86757cf2c785 to your computer and use it in GitHub Desktop.
Proof of concept of Prestashop Github Issue 14041 https://github.com/PrestaShop/PrestaShop/issues/14041
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Proof of concept of Prestashop Github Issue 14041 https://github.com/PrestaShop/PrestaShop/issues/14041 | |
* Put this code inside modules/issue14041/issue14041.php and install the module, it will replicate the issue any time the module's configuration is accessed. | |
*/ | |
class Issue14041 extends Module | |
{ | |
public function __construct() | |
{ | |
$this->name = 'issue14041'; | |
$this->tab = 'others'; | |
$this->version = '1.0.0'; | |
$this->author = 'R. Kazeno'; | |
$this->need_instance = 0; | |
$this->bootstrap = true; | |
parent::__construct(); | |
$this->displayName = $this->l('Issue 14041 Proof of Concept'); | |
$this->description = $this->l('Do not install this module in any store you care about, as it will remove the contents of most shopping carts upon entering its configuration page.'); | |
} | |
public function getContent() | |
{ | |
(new Combination())->deleteAssociations(); | |
return 'All the products without combinations should have been removed now from all shopping carts.'; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment