Remove test clocks
This commit is contained in:
parent
55763f8027
commit
bb690caac3
|
@ -97,7 +97,7 @@ export class StripeProvisioner extends BasicProvisioner {
|
||||||
[Tier.Premium]: {
|
[Tier.Premium]: {
|
||||||
order: 1,
|
order: 1,
|
||||||
name: "Premium",
|
name: "Premium",
|
||||||
description: "Power up your password manager!",
|
description: "Advanced multi-factor authentication, encrypted file storage and more!",
|
||||||
minSeats: undefined,
|
minSeats: undefined,
|
||||||
maxSeats: undefined,
|
maxSeats: undefined,
|
||||||
features: [
|
features: [
|
||||||
|
@ -336,13 +336,8 @@ export class StripeProvisioner extends BasicProvisioner {
|
||||||
// Create a new customer
|
// Create a new customer
|
||||||
if (!customer || customer.deleted) {
|
if (!customer || customer.deleted) {
|
||||||
const account = accountId ? await this.storage.get(Account, accountId).catch(() => null) : null;
|
const account = accountId ? await this.storage.get(Account, accountId).catch(() => null) : null;
|
||||||
const testClock = await this._stripe.testHelpers.testClocks.create({
|
|
||||||
name: `Test Clock for ${email}`,
|
|
||||||
frozen_time: Math.floor(Date.now() / 1000),
|
|
||||||
});
|
|
||||||
customer = await this._stripe.customers.create({
|
customer = await this._stripe.customers.create({
|
||||||
email,
|
email,
|
||||||
test_clock: testClock.id,
|
|
||||||
name: account?.name,
|
name: account?.name,
|
||||||
metadata: {
|
metadata: {
|
||||||
account: accountId!,
|
account: accountId!,
|
||||||
|
|
Loading…
Reference in New Issue