File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ import SessionContext from '../../context/SessionContext';
10
10
11
11
// Utility functions
12
12
import { formatDate } from '../../functions/DateFormat' ;
13
+ import { fromBase64 } from '../../util' ;
13
14
14
15
// Hooks
15
16
import useFetchPresentations from '../../hooks/useFetchPresentations' ;
@@ -28,8 +29,10 @@ const HistoryDetail = () => {
28
29
29
30
useEffect ( ( ) => {
30
31
if ( history . length > 0 ) {
31
- const verifiableCredentials = [ history [ 0 ] . presentation ] ;
32
- setMatchingCredentials ( verifiableCredentials ) ;
32
+ setMatchingCredentials ( history [ 0 ] . presentation . startsWith ( "b64:" ) ?
33
+ [ ...JSON . parse ( new TextDecoder ( ) . decode ( fromBase64 ( history [ 0 ] . presentation . replace ( "b64:" , "" ) ) ) ) ] :
34
+ [ history [ 0 ] . presentation ]
35
+ ) ;
33
36
}
34
37
} , [ history ] ) ;
35
38
You can’t perform that action at this time.
0 commit comments