Skip to content

Commit

Permalink
solve object interpolation issue noassign
Browse files Browse the repository at this point in the history
  • Loading branch information
Boetto Andrea committed Feb 27, 2018
1 parent cedc36d commit 16bbba4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions dist/angular-permission.js
Original file line number Diff line number Diff line change
Expand Up @@ -767,12 +767,13 @@
$scope.$watchGroup(['permission.only', 'permission.except', 'sref', 'permissionOptions'],
function () {
try {
var options=angular.copy(permission.options);
if (angular.isString(permission.options)){
permission.options=$scope.$eval(permission.options);
options=$scope.$eval(options);
}
if (isSrefStateDefined()) {
var PermStateAuthorization = $injector.get('PermStateAuthorization');
PermStateAuthorization.authorizeByStateName(permission.sref,permission.options)
PermStateAuthorization.authorizeByStateName(permission.sref,options)
.then(function () {
onAuthorizedAccess();
})
Expand Down

0 comments on commit 16bbba4

Please sign in to comment.