How to get user object in abilities source file in Ember-can addon. This is how my abilities file looks like.
import Ember from 'ember';
import { Ability } from 'ember-can';
export default Ability.extend({
canWrite: Ember.computed('user.isAdmin', function() {
return this.get('user.isAdmin');
})
});
Aucun commentaire:
Enregistrer un commentaire