update ng-directive