11import { RequestTracer , PrebuildTransactionOptions , Memo , KeyIndices } from '@bitgo/sdk-core' ;
2- import { createEnclavedExpressClient } from './enclavedExpressClient' ;
32import logger from '../logger' ;
43import { MasterApiSpecRouteRequest } from './routers/masterApiSpec' ;
54import { isMasterExpressConfig } from '../initConfig' ;
@@ -21,10 +20,7 @@ export async function handleSendMany(req: MasterApiSpecRouteRequest<'v1.wallet.s
2120 if ( ! isMasterExpressConfig ( req . config ) ) {
2221 throw new Error ( 'Configuration must be in master express mode' ) ;
2322 }
24- const enclavedExpressClient = createEnclavedExpressClient ( req . config , req . params . coin ) ;
25- if ( ! enclavedExpressClient ) {
26- throw new Error ( 'Please configure enclaved express configs to sign the transactions.' ) ;
27- }
23+ const enclavedExpressClient = req . enclavedExpressClient ;
2824 const reqId = new RequestTracer ( ) ;
2925 const bitgo = req . bitgo ;
3026 const baseCoin = bitgo . coin ( req . params . coin ) ;
@@ -96,7 +92,7 @@ export async function handleSendMany(req: MasterApiSpecRouteRequest<'v1.wallet.s
9692 const err = e as Error ;
9793 logger . error ( 'transaction prebuild failed local validation:' , err . message ) ;
9894 logger . error ( 'transaction prebuild:' , JSON . stringify ( txPrebuilt , null , 2 ) ) ;
99- throw new Error ( `Transaction prebuild failed local validation: ${ err . message } ` ) ;
95+ throw new Error ( `Transaction prebuild failed local validation: ${ err . message } ` ) ;
10096 }
10197
10298 logger . debug ( 'Tx prebuild: %s' , JSON . stringify ( txPrebuilt , null , 2 ) ) ;
0 commit comments