mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-27 10:42:45 +03:00
Added list and update stripe requests
no-issue These will be used for listing and updating webhooks on configuration
This commit is contained in:
parent
11a5a9ac69
commit
d1b29fd0b7
@ -4,16 +4,26 @@ const retrieve = createStripeRequest(function (stripe, resource, id) {
|
|||||||
return stripe[resource].retrieve(id);
|
return stripe[resource].retrieve(id);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const list = createStripeRequest(function (stripe, resource, options) {
|
||||||
|
return stripe[resource].list(options);
|
||||||
|
});
|
||||||
|
|
||||||
const create = createStripeRequest(function (stripe, resource, object) {
|
const create = createStripeRequest(function (stripe, resource, object) {
|
||||||
return stripe[resource].create(object);
|
return stripe[resource].create(object);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const update = createStripeRequest(function (stripe, resource, id, object) {
|
||||||
|
return stripe[resource].update(id, object);
|
||||||
|
});
|
||||||
|
|
||||||
const del = createStripeRequest(function (stripe, resource, id) {
|
const del = createStripeRequest(function (stripe, resource, id) {
|
||||||
return stripe[resource].del(id);
|
return stripe[resource].del(id);
|
||||||
});
|
});
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
retrieve,
|
retrieve,
|
||||||
|
list,
|
||||||
create,
|
create,
|
||||||
|
update,
|
||||||
del
|
del
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user