File tree 5 files changed +8
-14
lines changed
5 files changed +8
-14
lines changed Original file line number Diff line number Diff line change @@ -10,9 +10,6 @@ REACT_APP_NODE_2 = "https://bsc-dataseed1.defibit.io"
10
10
# 10+ nodes balanced in each region, global
11
11
REACT_APP_NODE_3 = " https://bsc-dataseed.binance.org"
12
12
13
- # Google Cloud Infrastructure Endpoint - Global
14
- REACT_APP_NODE_4 = " https://nodes.pancakeswap.com/"
15
-
16
13
REACT_APP_GRAPH_API_PROFILE = " https://api.thegraph.com/subgraphs/name/pancakeswap/profile"
17
14
REACT_APP_GRAPH_API_PREDICTION = " https://api.thegraph.com/subgraphs/name/pancakeswap/prediction-v2"
18
15
REACT_APP_GRAPH_API_LOTTERY = " https://api.thegraph.com/subgraphs/name/pancakeswap/lottery"
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ REACT_APP_NODE_2 = "https://bsc-dataseed1.defibit.io"
11
11
REACT_APP_NODE_3 = " https://bsc-dataseed.binance.org"
12
12
13
13
# Google Cloud Infrastructure Endpoint - Global
14
- # REACT_APP_NODE_4 = "https://nodes.pancakeswap.com/"
14
+ # REACT_APP_NODE_ALT = "https://nodes.pancakeswap.com/"
15
15
16
16
REACT_APP_GRAPH_API_PROFILE = " https://api.thegraph.com/subgraphs/name/pancakeswap/profile"
17
17
REACT_APP_GRAPH_API_PREDICTION = " https://api.thegraph.com/subgraphs/name/pancakeswap/prediction-v2"
Original file line number Diff line number Diff line change @@ -3,4 +3,3 @@ REACT_APP_CHAIN_ID = "56"
3
3
REACT_APP_NODE_1 = " https://bsc-dataseed1.ninicoin.io"
4
4
REACT_APP_NODE_2 = " https://bsc-dataseed1.ninicoin.io"
5
5
REACT_APP_NODE_3 = " https://bsc-dataseed1.ninicoin.io"
6
- REACT_APP_NODE_4 = " https://bsc-dataseed1.ninicoin.io"
Original file line number Diff line number Diff line change 6
6
< link rel ="preconnect " href ="%REACT_APP_NODE_1% " />
7
7
< link rel ="preconnect " href ="%REACT_APP_NODE_2% " />
8
8
< link rel ="preconnect " href ="%REACT_APP_NODE_3% " />
9
- <!-- <link rel="preconnect" href="%REACT_APP_NODE_4%" /> REMOVED UNTIL GOOGLE NODE IS FIXED -->
10
9
< link rel ="preconnect " href ="https://fonts.gstatic.com " />
11
10
< link href ="https://fonts.googleapis.com/css2?family=Kanit:wght@400;600&display=swap " rel ="stylesheet " />
12
11
< link rel ="shortcut icon " href ="%PUBLIC_URL%/favicon.ico " />
Original file line number Diff line number Diff line change 1
1
import sample from 'lodash/sample'
2
2
3
+ if ( ! process . env . REACT_APP_NODE_1 || ! process . env . REACT_APP_NODE_2 || ! process . env . REACT_APP_NODE_3 ) {
4
+ throw Error ( 'One base RPC URL is undefined' )
5
+ }
6
+
3
7
// Array of available nodes to connect to
4
- export const nodes = [
5
- process . env . REACT_APP_NODE_1 ,
6
- process . env . REACT_APP_NODE_2 ,
7
- process . env . REACT_APP_NODE_3 ,
8
- // process.env.REACT_APP_NODE_4,
9
- ]
8
+ export const nodes = [ process . env . REACT_APP_NODE_1 , process . env . REACT_APP_NODE_2 , process . env . REACT_APP_NODE_3 ]
10
9
11
- if ( process . env . NODE_ENV === 'production' ) {
12
- nodes . push ( process . env . REACT_APP_NODE_4 )
10
+ if ( process . env . NODE_ENV === 'production' && process . env . REACT_APP_NODE_ALT ) {
11
+ nodes . push ( process . env . REACT_APP_NODE_ALT )
13
12
}
14
13
15
14
const getNodeUrl = ( ) => {
You can’t perform that action at this time.
0 commit comments