Skip to content

Commit f96a1ba

Browse files
committed
fix(angular): do not launch the directive if autocomplete has a value
Closes #136
1 parent be1dc19 commit f96a1ba

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/angular/directive.js

+1
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ angular.module('algolia.autocomplete', [])
3636
datasets: '&aaDatasets'
3737
},
3838
link: function(scope, element, attrs) {
39+
if (!element.hasClass('autocomplete') && attrs.autocomplete !== '') return;
3940
attrs = attrs; // no-unused-vars
4041
scope.options = $parse(scope.options)(scope);
4142
if (!scope.options) {

0 commit comments

Comments
 (0)