I have an adapter that queries a url using user specific data. I need a way to get data from the simple auth session to the adapter.
I tried to inject the session into the adapter Adapter
session: Ember.inject.service('session'),
But this is throwing an error
Error while processing route: videos.index Attempting to inject an unknown injection:
service:session
Error: Attempting to inject an unknown injection:service:session
Edit:
In the adapter I can retrieve the user data via the container.
Adapter:
var container = this.get('container');
var currentUser = container.lookup('session:withCurrentUser');
console.log('currentUser ID', currentUser.get('secure.userData.id'));
Would this be the recommended way to do it?