We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
Conditions | 5 |
Paths | 3 |
Total Lines | 20 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | 'use strict'; |
||
45 | confirm: function() { |
||
46 | this.showLoader(); |
||
47 | |||
48 | let close = _.bind(function() { |
||
49 | this.$el.modal('hide'); |
||
50 | this.hideLoader(); |
||
51 | }, this); |
||
52 | |||
53 | if (_.isFunction(callback)) { |
||
54 | let response = callback.call(this, true); |
||
55 | |||
56 | if (response instanceof Promise || response instanceof $.Deferred || _.result(response, 'then')) { |
||
57 | response.then(close); |
||
58 | } else { |
||
59 | close.apply(this) |
||
60 | } |
||
61 | } else { |
||
62 | close.apply(this); |
||
63 | } |
||
64 | } |
||
65 | }); |
||
74 | }); |