File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed
governance/xc_admin/packages/xc_admin_frontend/hooks Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ import { ClusterContext } from '../contexts/ClusterContext'
10
10
import { deriveWsUrl , pythClusterApiUrls } from '../utils/pythClusterApiUrl'
11
11
import {
12
12
ProgramType ,
13
- getConfigFromRawAccounts ,
13
+ getConfig ,
14
14
RawConfig ,
15
15
MappingRawConfig ,
16
16
ProductRawConfig ,
@@ -57,10 +57,11 @@ export const usePyth = (): PythHookData => {
57
57
if ( cancelled ) return
58
58
59
59
// Use the functional approach to parse the accounts
60
- const parsedConfig = getConfigFromRawAccounts [ ProgramType . PYTH_CORE ] (
61
- allPythAccounts ,
62
- cluster as PythCluster
63
- )
60
+ const parsedConfig = getConfig [ ProgramType . PYTH_CORE ] ( {
61
+ programType : ProgramType . PYTH_CORE ,
62
+ accounts : allPythAccounts ,
63
+ cluster : cluster as PythCluster ,
64
+ } )
64
65
65
66
// Verify all accounts were processed
66
67
const remainingAccounts = allPythAccounts . filter ( ( account ) => {
@@ -74,7 +75,7 @@ export const usePyth = (): PythHookData => {
74
75
)
75
76
}
76
77
77
- setRawConfig ( parsedConfig )
78
+ setRawConfig ( parsedConfig as RawConfig )
78
79
setIsLoading ( false )
79
80
} catch ( e ) {
80
81
if ( cancelled ) return
You can’t perform that action at this time.
0 commit comments