Update code style
This commit is contained in:
parent
d32632f768
commit
b2542a27c3
1 changed files with 8 additions and 8 deletions
|
@ -5,15 +5,15 @@ const v8Util = process.atomBinding('v8_util')
|
|||
|
||||
module.exports = {
|
||||
|
||||
canMakePayments: function() {
|
||||
canMakePayments: function () {
|
||||
return binding.canMakePayments()
|
||||
},
|
||||
|
||||
getReceiptURL: function() {
|
||||
getReceiptURL: function () {
|
||||
return binding.getReceiptURL()
|
||||
},
|
||||
|
||||
purchaseProduct: function(productID, quantity = 1, callback) {
|
||||
purchaseProduct: function (productID, quantity = 1, callback) {
|
||||
if (typeof productID !== 'string') {
|
||||
throw new TypeError('productID must be a string')
|
||||
}
|
||||
|
@ -24,7 +24,7 @@ module.exports = {
|
|||
return binding.purchaseProduct(productID, quantity, callback)
|
||||
},
|
||||
|
||||
addTransactionListener: function(callback) {
|
||||
addTransactionListener: function (callback) {
|
||||
if (typeof callback !== 'function') {
|
||||
throw new TypeError('callback must be a function')
|
||||
}
|
||||
|
@ -32,8 +32,8 @@ module.exports = {
|
|||
}
|
||||
}
|
||||
|
||||
// Mark standard asynchronous functions.
|
||||
v8Util.setHiddenValue(
|
||||
module.exports.purchaseProduct, 'asynchronous', true)
|
||||
// Mark standard asynchronous functions.
|
||||
v8Util.setHiddenValue(
|
||||
module.exports.addTransactionListener, 'asynchronous', true)
|
||||
module.exports.purchaseProduct, 'asynchronous', true)
|
||||
v8Util.setHiddenValue(
|
||||
module.exports.addTransactionListener, 'asynchronous', true)
|
||||
|
|
Loading…
Add table
Reference in a new issue