mirror of
https://github.com/datahub-project/datahub.git
synced 2025-12-29 10:57:52 +00:00
Renames current-user service on application route to avoid conflict with legacy use of currentUser in various controllers
This commit is contained in:
parent
778147739b
commit
4ae3b06dba
@ -11,7 +11,7 @@ const {
|
||||
|
||||
export default Route.extend(ApplicationRouteMixin, {
|
||||
// Injected Ember#Service for the current user
|
||||
currentUser: service(),
|
||||
sessionUser: service('current-user'),
|
||||
|
||||
/**
|
||||
* Attempt to load the current user
|
||||
@ -38,7 +38,7 @@ export default Route.extend(ApplicationRouteMixin, {
|
||||
* @private
|
||||
*/
|
||||
_loadCurrentUser() {
|
||||
return get(this, 'currentUser')
|
||||
return get(this, 'sessionUser')
|
||||
.load()
|
||||
.catch(() => get(this, 'session').invalidate());
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user