Sim
Well-known member
Referring to the new automatic file cleanup feature in XF 2.3, the announcement says the following:
Is there a reason why I shouldn't just add this to every Setup.php file for my addons?
If so, why doesn't XF simply call this automatically whenever an addon is upgraded?
Developers who wish to trigger an automatic clean up of their own files, can do so by calling the following from within their add-on Setup class in the postUpgrade method:
PHP:
$this->enqueuePostUpgradeCleanUp();
My question is - under what circumstances would you not want to run this?Is there a reason why I shouldn't just add this to every Setup.php file for my addons?
If so, why doesn't XF simply call this automatically whenever an addon is upgraded?