Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnnabel Dunstone <annabel.dunstone@gmail.com>2016-08-17 04:34:49 +0300
committerAnnabel Dunstone <annabel.dunstone@gmail.com>2016-08-17 04:34:49 +0300
commite5f9fdf90c1d59a07f76919e9d94599b494ac50f (patch)
tree2d1c8275733fc39005368a5d15366211b321ffa5 /app/assets/javascripts/merge_request_tabs.js
parent30d578f6345c3807158e16eb73b28f290e416d16 (diff)
Refactor merge_request-tabs
Diffstat (limited to 'app/assets/javascripts/merge_request_tabs.js')
-rw-r--r--app/assets/javascripts/merge_request_tabs.js14
1 files changed, 6 insertions, 8 deletions
diff --git a/app/assets/javascripts/merge_request_tabs.js b/app/assets/javascripts/merge_request_tabs.js
index a21cdbc8a10..1bba69a255a 100644
--- a/app/assets/javascripts/merge_request_tabs.js
+++ b/app/assets/javascripts/merge_request_tabs.js
@@ -188,14 +188,12 @@
}
return this._get({
url: source + ".json",
- success: (function(_this) {
- return function(data) {
- document.querySelector("div#pipelines").innerHTML = data.html;
- gl.utils.localTimeAgo($('.js-timeago', 'div#pipelines'));
- _this.pipelinesLoaded = true;
- return _this.scrollToElement("#pipelines");
- };
- })(this)
+ success: function(data) {
+ $('#pipelines').html(data.html);
+ gl.utils.localTimeAgo($('.js-timeago', '#pipelines'));
+ this.pipelinesLoaded = true;
+ return this.scrollToElement("#pipelines");
+ }.bind(this)
});
};