Skip to content

Commit

Permalink
fix(angular): do not launch the directive if autocomplete has a value
Browse files Browse the repository at this point in the history
Closes #136
  • Loading branch information
Jerska committed Jan 6, 2017
1 parent be1dc19 commit f96a1ba
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/angular/directive.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ angular.module('algolia.autocomplete', [])
datasets: '&aaDatasets'
},
link: function(scope, element, attrs) {
if (!element.hasClass('autocomplete') && attrs.autocomplete !== '') return;
attrs = attrs; // no-unused-vars
scope.options = $parse(scope.options)(scope);
if (!scope.options) {
Expand Down

0 comments on commit f96a1ba

Please sign in to comment.