I’m trying to build an adapter for a third-party api that requires a token (set in my App.User model). The adapter itself however is registered to another model (App.Workauth).
Everything works fine when I navigate to the route. However when I go directly to the url, the required information for the current App.User is not yet loaded.
I’m trying to sort out how to make sure I have the username and token attributes from the App.User model before I try to load up the App.Workauth route…
This could very likely be the trick to solving the situation… Although unfortunately this information isn’t available until I’ve authenticated the current user… so I’m not sure that I can use this exactly as it currently stands, if it can only be invoked on initial load…
I was thinking the router facelift may hold the key, but that still seems to be a trick… im new to promises as well so i have a few new things to learn here.