Runtime error with mobile app: "then is not a function"
Question
Application Type
Mobile
Service Studio Version
11.12.7 (Build 51940)

At runtime, I get this error in the console when running the app in a browser:

mycontroller.default.getAlertItem$Action(...).then is not a function TypeError: mycontroller.default.getAlertItem$Action(...).then is not a function

getAlertItem is a client action and web blocks are involved, but I'm not sure how to troubleshoot this one. 

Any ideas?

mvp_badge
MVP

Hi Lorenzo,

Not sure why you get the error, but I can tell at least that you get this error because mycontroller.default.getAlertItem$Action apparently does not return a promise, as .then is one of the functions of a promise.

Does your client action include some custom JavaScript code?

Regards,

Daniel

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.