Jump to content

Question on overriding classes/controllers from a module


Recommended Posts



I want to override one core controller, but instead of changing in override folder, I want to provide my new version of the controller directly from the module. In this way, users will not have to copy other files.


I have observed that if I place my controller under:




when the module is installed, all my code goes to the base override folder:




No problem until now. However, the big question is what happens if 2 different modules are overriding the same controller?

What is stored under override/controllers/front ?


I don't believe there is an aggregation, as it will be impossible. So how is this case treated?



Link to comment
Share on other sites

If another module overrides a DIFFERENT member function of the class then it will add that function to the override class.


If another module tries to override the same function then the module won't install and there will be an error message :(

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...