From e56dc7fb833be23a4cd5f2156b898c62344366d9 Mon Sep 17 00:00:00 2001 From: Oleksandr Pavlovskyi Date: Wed, 3 Apr 2024 13:35:54 +0300 Subject: [PATCH] feat: add webhook controller --- libs/stripe/package.json | 2 +- libs/stripe/src/lib/stripe.module.ts | 60 ++++++++++++++-------------- 2 files changed, 31 insertions(+), 31 deletions(-) diff --git a/libs/stripe/package.json b/libs/stripe/package.json index 037c4ed..76d440e 100644 --- a/libs/stripe/package.json +++ b/libs/stripe/package.json @@ -1,6 +1,6 @@ { "name": "@valor/nestjs-stripe", - "version": "0.0.21", + "version": "0.0.22", "type": "commonjs", "private": false, "author": "opavlovskyi-valor-software", diff --git a/libs/stripe/src/lib/stripe.module.ts b/libs/stripe/src/lib/stripe.module.ts index b657aa2..20eed6a 100644 --- a/libs/stripe/src/lib/stripe.module.ts +++ b/libs/stripe/src/lib/stripe.module.ts @@ -1,41 +1,41 @@ import { CanActivate, DynamicModule, Module, ModuleMetadata, Provider, Type, } from '@nestjs/common'; import { STRIPE_AUTH_GUARD } from './stripe-auth.guard'; import { StripeConfig, STRIPE_CONFIG } from './stripe.config'; -import { StripeController } from './stripe.controller'; +// import { StripeController } from './stripe.controller'; import { StripeLogger } from './stripe.logger'; import { StripeService } from './stripe.service'; import { WebhookController } from './webhook/webhook.controller'; import { WebhookService } from './webhook/webhook.service'; -import { - CheckoutSessionController, - CustomerController, - PaymentIntentController, - PaymentMethodController, - PriceController, - ProductController, - SubscriptionController, - InvoiceController, - UsageRecordController, - QuotesController, - SubscriptionScheduleController, -} from './controllers'; -import { TestClocksController } from './controllers/test-clock.controller'; +// import { +// CheckoutSessionController, +// CustomerController, +// PaymentIntentController, +// PaymentMethodController, +// PriceController, +// ProductController, +// SubscriptionController, +// InvoiceController, +// UsageRecordController, +// QuotesController, +// SubscriptionScheduleController, +// } from './controllers'; +// import { TestClocksController } from './controllers/test-clock.controller'; const controllerList = [ - PaymentIntentController, - CheckoutSessionController, - CustomerController, - PaymentMethodController, - PriceController, - ProductController, - SubscriptionController, - SubscriptionScheduleController, - InvoiceController, - UsageRecordController, - QuotesController, - TestClocksController, + // PaymentIntentController, + // CheckoutSessionController, + // CustomerController, + // PaymentMethodController, + // PriceController, + // ProductController, + // SubscriptionController, + // SubscriptionScheduleController, + // InvoiceController, + // UsageRecordController, + // QuotesController, + // TestClocksController, - StripeController, + // StripeController, WebhookController ]; const providerList = [StripeService, StripeLogger, WebhookService]; @@ -60,7 +60,7 @@ export interface StripeConfigAsyncOptions } @Module({ - // controllers: controllerList, + controllers: controllerList, providers: providerList, exports: exportList, }) @@ -68,7 +68,7 @@ export class StripeModule { static forRoot(config: StripeConfig, authGuard: Type): DynamicModule { return { module: StripeModule, - // controllers: controllerList, + controllers: controllerList, providers: [ { provide: STRIPE_CONFIG,