File tree Expand file tree Collapse file tree 1 file changed +7
-8
lines changed
packages/transactional/src/lib Expand file tree Collapse file tree 1 file changed +7
-8
lines changed Original file line number Diff line number Diff line change 11import { Provider } from '@nestjs/common' ;
2- import { ClsModule , ClsPlugin } from 'nestjs-cls' ;
2+ import { ClsModule , ClsPluginBase } from 'nestjs-cls' ;
33import { getTransactionToken } from './inject-transaction.decorator' ;
44import {
55 MergedTransactionalAdapterOptions ,
@@ -13,16 +13,15 @@ import {
1313} from './symbols' ;
1414import { getTransactionHostToken , TransactionHost } from './transaction-host' ;
1515
16- export class ClsPluginTransactional implements ClsPlugin {
17- name : string ;
16+ export class ClsPluginTransactional extends ClsPluginBase {
1817 providers : Provider [ ] ;
19- imports : any [ ] = [ ] ;
20- exports : any [ ] = [ ] ;
2118
2219 constructor ( options : TransactionalPluginOptions < any , any , any > ) {
23- this . name = options . connectionName
24- ? `cls-plugin-transactional-${ options . connectionName } `
25- : 'cls-plugin-transactional' ;
20+ super (
21+ options . connectionName
22+ ? `cls-plugin-transactional-${ options . connectionName } `
23+ : 'cls-plugin-transactional' ,
24+ ) ;
2625 this . imports . push ( ...( options . imports ?? [ ] ) ) ;
2726 const transactionHostToken = getTransactionHostToken (
2827 options . connectionName ,
You can’t perform that action at this time.
0 commit comments