File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ async function handler(req: NextApiRequest, res: NextApiResponse) {
4646 const vc = decodeJWT ( objectPath . get ( verifiedAuthResponse , 'payload.vp.verifiableCredential.0' ) ) ;
4747 if ( objectPath . has ( doc , 'vc' ) ) {
4848 const vc_arr = objectPath . get ( doc , 'vc' ) ;
49- vc_arr . push ( vc ) ;
49+ vc_arr . push ( vc . payload ) ;
5050 objectPath . set ( doc , 'vc' , vc_arr ) ;
5151 } else {
5252 objectPath . set ( doc , 'vc.0' , vc ) ;
@@ -55,7 +55,7 @@ async function handler(req: NextApiRequest, res: NextApiResponse) {
5555 await gnap . insert ( doc ) ;
5656 if ( objectPath . has ( patient_doc , 'vc' ) ) {
5757 const vc_arr1 = objectPath . get ( patient_doc , 'vc' ) ;
58- vc_arr1 . push ( vc ) ;
58+ vc_arr1 . push ( vc . payload ) ;
5959 objectPath . set ( patient_doc , 'vc' , vc_arr1 ) ;
6060 } else {
6161 objectPath . set ( patient_doc , 'vc.0' , vc ) ;
You can’t perform that action at this time.
0 commit comments