Jump to content

Need some help regarding class override


J.Sahu

Recommended Posts

Hi,

 

I am creating an override in which the $default_routes  array is getting overridden inside Dispatcher.php

 

When I am installing everything works fine but at the time uninstall it is not removing the entire code instead removing only one line i.e. public $default_routes = array(. (Please check the attached file)

 

As I believe the default feature of PS is, it checks and removes the function which are getting overridden but what can I do as I am only overriding one variable ?

 

My aim is to check if a module is active or not. If module active then the override codes will work.

 

So I have tried to use this

 

$module = Module::getInstanceByName('mymodule');

 

But as there is no function so I am unable to check.

 

It will be great if someone will give some idea about these implementations. 

 

Thank You

Dispatcher.php

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...