I have to add a user is active or not check before the user login for any place in my site. How can I do it? I mean which module or function need to override in my site.

Please help me to solve this issue.


You have to override LoginPost Controller and in it's execute function do your code, In this controller you will get all the customer information before login, you can check customer is active or not then return. To override follow this: https://magento.stackexchange.com/a/179731/81151

| improve this answer | |
  • He doesn't want to check if customer is logged in or not, he wants to check if customer status is active or not before login – Shoaib Munir Oct 1 '19 at 11:42
  • so you mean i need to overide the isLoggedIn function? – AKM Oct 1 '19 at 11:42
  • @Shoaib Munir Yes, i need check as per your comment. – AKM Oct 1 '19 at 11:43
  • 1
    @AKM please check the updated answer – temper Oct 1 '19 at 11:45

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.