Skip to content
This repository was archived by the owner on Sep 2, 2020. It is now read-only.

Commit 66695ff

Browse files
committed
chore(clean): cleanup code
1 parent cd4aebd commit 66695ff

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/bootstrap-affix.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,10 @@ angular.module('mgcrea.bootstrap.affix', ['mgcrea.jquery', 'mgcrea.debounce'])
2828
affix = false;
2929
}
3030

31-
console.warn('affix', affix);
3231
if (affixed === affix) return;
3332

3433
affixed = affix;
3534
unpin = affix === 'bottom' ? position.top - scrollTop : null;
36-
console.warn('unpin', unpin);
3735

3836
el.removeClass(reset).addClass('affix' + (affix ? '-' + affix : ''));
3937

@@ -43,11 +41,11 @@ angular.module('mgcrea.bootstrap.affix', ['mgcrea.jquery', 'mgcrea.debounce'])
4341
restrict: 'EAC',
4442
link: function postLink(scope, iElement, iAttrs) {
4543

46-
angular.element($window).bind('scroll.affix', function() {
44+
angular.element($window).bind('scroll', function() {
4745
checkPosition(scope, iElement, iAttrs);
4846
});
4947

50-
angular.element($window).bind('click.affix', function() {
48+
angular.element($window).bind('click', function() {
5149
setTimeout(function() {
5250
checkPosition(scope, iElement, iAttrs);
5351
}, 1);

0 commit comments

Comments
 (0)