. Thank you for taking time to read the article. Can you kindly (if possible) push your work to github and share with me? that will be easy for me to debug what is happening.
But User.hook not being a function basically means you are calling the hook on the wrong model or instance of User. Kindly check your code to make sure you are passing User as the model as your hook is supposed to be bound to it.
Do you have the code of this app somewhere in Github so I can clone directly from there and study. I am also getting User.hook not a function error.
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.