carcass-stripe
Advanced tools
Comparing version 0.1.0 to 0.1.1
@@ -46,3 +46,3 @@ var Stripe, carcass, config, debug, highland, httpError, stripe; | ||
Stripe.prototype.getClient = function(apiKey) { | ||
Stripe.prototype.getClient = function(secretKey) { | ||
var client, _ref; | ||
@@ -54,5 +54,5 @@ client = this.client(); | ||
config = (_ref = this.config()) != null ? _ref : {}; | ||
debug('Stripe api key', apiKey); | ||
debug('Stripe secret key', secretKey); | ||
debug('Stripe %s, configs %j', this.id(), config); | ||
client = stripe(apiKey); | ||
client = stripe(secretKey); | ||
this.client(client); | ||
@@ -59,0 +59,0 @@ return client; |
{ | ||
"stripe": { | ||
"apiKey": "TjNBFkN3UMEzE7RBXxIJ7Eby", | ||
"plan": "devops_free" | ||
}, | ||
// For singletons/couch, which has 'couch' as the id and the config name. | ||
@@ -7,0 +3,0 @@ "couch": { |
{ | ||
"stripe": { | ||
"apiKey": "p4lsGxgHqf7UZk9cCQ2erh1YelSVH8CZ", | ||
"plan": "devops_free" | ||
"secretKey": "p4lsGxgHqf7UZk9cCQ2erh1YelSVH8CZ" | ||
}, | ||
@@ -6,0 +5,0 @@ "badCouch": { |
@@ -55,3 +55,3 @@ var Lorem, debug, lib, modella, validation; | ||
debug('String config %j', config); | ||
return lib.singletons.stripe.getClient(config.apiKey); | ||
return lib.singletons.stripe.getClient(config.secretKey); | ||
}; | ||
@@ -58,0 +58,0 @@ |
@@ -6,1 +6,6 @@ | ||
* Initial release. | ||
0.1.1 / 2014-08-21 | ||
================== | ||
* apiKey -> secretKey |
{ | ||
"name": "carcass-stripe", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"description": "(Node.js) A simple wrap of stripe APIs, in Carcass style.", | ||
@@ -5,0 +5,0 @@ "author": { |
// var debug = require('debug')('carcass:test'); | ||
var should = require('should'); | ||
require('should'); | ||
var uid = require('uid2'); | ||
@@ -54,7 +54,7 @@ var example = require('../example'); | ||
lorem.set({ | ||
stripe: { | ||
customerId: customer.id | ||
} | ||
}); | ||
lorem.set({ | ||
stripe: { | ||
customerId: customer.id | ||
} | ||
}); | ||
@@ -61,0 +61,0 @@ done(); |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
86836
1911