Skip to content

Commit

Permalink
Merge pull request #16 from bnb-chain/revert-15-fix-walletconnect
Browse files Browse the repository at this point in the history
Revert "fix:walletconnect"
  • Loading branch information
constwz authored Dec 15, 2023
2 parents 3849bf0 + c6b306b commit b3b32da
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/hooks/wallets/useOnboard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ export const useInitOnboard = () => {
const onboard = useStore()
const customRpc = useAppSelector(selectRpc)

//useInitPairing()
useInitPairing()

useEffect(() => {
if (configs.length > 0 && chain) {
Expand Down
18 changes: 9 additions & 9 deletions src/services/pairing/hooks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,15 @@ export const useInitPairing = () => {
const canConnect = !connector?.connected && !isConnecting
const isSupported = isPairingSupported(chain?.disabledWallets)

useEffect(() => {
const _pairingConnector = new WalletConnect({
bridge: WC_BRIDGE,
storageId: local.getPrefixedKey(PAIRING_MODULE_STORAGE_ID),
clientMeta: getClientMeta(),
})

setPairingConnector(_pairingConnector)
}, [])
//useEffect(() => {
// const _pairingConnector = new WalletConnect({
// bridge: WC_BRIDGE,
// storageId: local.getPrefixedKey(PAIRING_MODULE_STORAGE_ID),
// clientMeta: getClientMeta(),
// })

//setPairingConnector(_pairingConnector)
//}, [])

const createSession = useCallback(() => {
if (!canConnect || !chain || !isSupported || !onboard) {
Expand Down

0 comments on commit b3b32da

Please sign in to comment.