Is there a way to discard/revert the changes I made with InstallData/UpgradeData scripts without having to go to database and revert changes there manually?

I know there is Uninstall.php, but it only works if your module is a composer package.


NO there is not (at least at the time I'm writing this).
The uninstall file, as you say, is only executed for composer installed packages.
For other modules you have to remove manually what you added via the install/update scripts.

  • @Rudolph I hear ya. It would be nice to make it work for all modules. – Marius Feb 9 '17 at 12:30
  • I agree with the statement that this sucks. Can anyone share some insight on why they added this constraint? – Giel Berkers Jul 20 '17 at 14:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.