From 237289320d622da35b2abb857642bcd38074e10f Mon Sep 17 00:00:00 2001 From: Jesse Tan Date: Wed, 6 Dec 2017 10:10:39 +0100 Subject: [PATCH] Remove need for bind() --- js/theme.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/theme.js b/js/theme.js index 6c0f844b..d54f7f12 100644 --- a/js/theme.js +++ b/js/theme.js @@ -31,7 +31,7 @@ function ThemeNav () { if (!self.linkScroll) { if (!self.winScroll) { self.winScroll = true; - requestAnimationFrame(self.onScroll.bind(self)); + requestAnimationFrame(function() { self.onScroll(); }); } } }); @@ -40,7 +40,7 @@ function ThemeNav () { self.win.on('resize', function () { if (!self.winResize) { self.winResize = true; - requestAnimationFrame(self.onResize.bind(self)); + requestAnimationFrame(function() { self.onResize(); }); } });