Overriding an existing action in plugin

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
4 years ago
I am trying to override an action from Nop.Web.Controllers.CommonController in my plugin. I think rerouting is unnecessary since I only want to modify backend logic and no views need changing. Am also not quite familiar with DI.

Plugin Code

public class CommonController : Nop.Web.Controllers.CommonController
    {
    }

ErrorList:
Error CS7036
There is no argument given that corresponds to the required formal parameter 'commonModelFactory' of 'CommonController.CommonController(ICommonModelFactory, ILanguageService, ICurrencyService, ILocalizationService, IWorkContext, IStoreContext, IQueuedEmailService, IEmailAccountService, IThemeContext, IGenericAttributeService, ICustomerActivityService, IVendorService, IWorkflowMessageService, TaxSettings, StoreInformationSettings, EmailAccountSettings, CommonSettings, LocalizationSettings, CaptchaSettings, VendorSettings)'
4 years ago
Edit: I created an empty constructor that inherited base controller so it's fixed for now.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.