Remove unused repository and related code from fallback processor
This commit is contained in:
parent
f229d31398
commit
fe06faf0e8
@ -1,9 +1,5 @@
|
|||||||
import { Injectable, Logger } from '@nestjs/common';
|
import { Injectable, Logger } from '@nestjs/common';
|
||||||
import { ConfigService } from '@nestjs/config';
|
import { ConfigService } from '@nestjs/config';
|
||||||
import { Payment } from '../entities/payment.entity';
|
|
||||||
import { InjectRepository } from '@nestjs/typeorm';
|
|
||||||
import { Repository } from 'typeorm';
|
|
||||||
import { ProcessorTypeEnum } from '../enumns/processor-type.enum';
|
|
||||||
import { MakePaymentToProcessorService } from '../services/make-payment-to-processor.service';
|
import { MakePaymentToProcessorService } from '../services/make-payment-to-processor.service';
|
||||||
import { CreatePaymentDto } from '../dto/create-payment.dto';
|
import { CreatePaymentDto } from '../dto/create-payment.dto';
|
||||||
|
|
||||||
@ -13,7 +9,6 @@ export class PaymentFallbackProcessor {
|
|||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
private readonly configService: ConfigService,
|
private readonly configService: ConfigService,
|
||||||
@InjectRepository(Payment) private readonly repository: Repository<Payment>,
|
|
||||||
private makePaymentToProcessorService: MakePaymentToProcessorService,
|
private makePaymentToProcessorService: MakePaymentToProcessorService,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
@ -27,10 +22,6 @@ export class PaymentFallbackProcessor {
|
|||||||
|
|
||||||
if (!responseExists) return false;
|
if (!responseExists) return false;
|
||||||
|
|
||||||
await this.repository.save({
|
|
||||||
...payment,
|
|
||||||
paymentProcessor: ProcessorTypeEnum.FALLBACK,
|
|
||||||
});
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user