I'm working in salesforce communities right now and making some edits to components. Specifically the forgot password component. I haven't touched the controller or helper, just adding some wording and changing styles within the lightning component. All of a sudden, I'm getting the error

Unable to find 'forgotPassowrd' on 'compound://c.forgotPassword'

From what I can tell, this is from the following line in the helper:

var action = component.get("c.forgotPassowrd");

There was no issue with this, even after I started adding elements and styles within the component. I can't narrow down what I might have done to all of a sudden make this not work. The controller within the component is still LightningForgotPasswordController and I haven't gotten rid of any of the aura attributes or anything like that. Any help or a direction to start looking would be greatly appreciated. Thanks!

  • do you have any js controller function with name forgotPassowrd – Manjot Singh Feb 16 '18 at 17:08
  • Can you please share the code – Arpit Sethi Feb 16 '18 at 17:20
  • Manjot Singh - It's just the default controller and helper from the forgotPassword component. I haven't changed anything, so there's a handleForgotPassword, but no straight forgotPassword. – Eric Strom Feb 16 '18 at 17:41

You have misspelled forgotPassword as forgotPassowrd. Because the javascript controller text does not match the apex controller method name, you receive the error.

| improve this answer | |
  • It seems like when you edit a built in lightning component, the copy that it lets you edit is littered with errors. After realizing that this was the problem I also noticed that by default all instances of 'helper' are spelled 'helpler' as well as some other places in the controller and helper that have switched around letters. – Eric Strom Feb 20 '18 at 1:57
  • That's unfortunate :( – techbusinessman Feb 20 '18 at 4:56

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