summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Greiling <mike@pixelcog.com>2017-05-08 14:01:27 -0500
committerMike Greiling <mike@pixelcog.com>2017-05-08 17:40:16 -0500
commita333f2026169b5efdf882fa7c4372baca0339ed7 (patch)
tree207fec2821d0b4ece19e70a08b4b3b882e857251
parent98b5dd9d510442b2d032dcb83959801c96179768 (diff)
downloadgitlab-ce-a333f2026169b5efdf882fa7c4372baca0339ed7.tar.gz
remove bind polyfill from line_highlighter.js
-rw-r--r--app/assets/javascripts/line_highlighter.js8
1 files changed, 3 insertions, 5 deletions
diff --git a/app/assets/javascripts/line_highlighter.js b/app/assets/javascripts/line_highlighter.js
index 3ac6dedf131..517f03d5aba 100644
--- a/app/assets/javascripts/line_highlighter.js
+++ b/app/assets/javascripts/line_highlighter.js
@@ -31,8 +31,6 @@ require('vendor/jquery.scrollTo');
// </div>
//
(function() {
- var bind = function(fn, me) { return function() { return fn.apply(me, arguments); }; };
-
this.LineHighlighter = (function() {
// CSS class applied to highlighted lines
LineHighlighter.prototype.highlightClass = 'hll';
@@ -47,9 +45,9 @@ require('vendor/jquery.scrollTo');
// hash - String URL hash for dependency injection in tests
hash = location.hash;
}
- this.setHash = bind(this.setHash, this);
- this.highlightLine = bind(this.highlightLine, this);
- this.clickHandler = bind(this.clickHandler, this);
+ this.setHash = this.setHash.bind(this);
+ this.highlightLine = this.highlightLine.bind(this);
+ this.clickHandler = this.clickHandler.bind(this);
this.highlightHash = this.highlightHash.bind(this);
this._hash = hash;
this.bindEvents();