Fix bad var context

This commit is contained in:
Samuel Georges 2016-02-14 20:10:36 +11:00
parent 659c7098b9
commit 049e5bcfc7
2 changed files with 4 additions and 2 deletions

View File

@ -24,6 +24,7 @@
$.oc = {}
var StripeLoadIndicator = function () {
var self = this
this.counter = 0
this.indicator = $('<div/>').addClass('stripe-loading-indicator loaded')
.append($('<div />').addClass('stripe'))
@ -31,7 +32,7 @@
this.stripe = this.indicator.find('.stripe')
$(document).ready(function(){
$(document.body).append(this.indicator)
$(document.body).append(self.indicator)
})
}

View File

@ -16,6 +16,7 @@
$.oc = {}
var StripeLoadIndicator = function () {
var self = this
this.counter = 0
this.indicator = $('<div/>').addClass('stripe-loading-indicator loaded')
.append($('<div />').addClass('stripe'))
@ -23,7 +24,7 @@
this.stripe = this.indicator.find('.stripe')
$(document).ready(function(){
$(document.body).append(this.indicator)
$(document.body).append(self.indicator)
})
}