File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -11,8 +11,8 @@ let isEventListenerCreated = false
11
11
module . exports . nftMintListener = function nftMintListener ( ) {
12
12
return ( req : Request , res : Response ) => {
13
13
try {
14
- const customHttpProvider = new ethers . JsonRpcProvider ( 'https ://sepolia.infura.io/v3/0b88ff4d03a647b8a4649e9bfdf6644f ')
15
- const contract = new ethers . Contract ( nftAddress , nftABI , customHttpProvider )
14
+ const provider = new ethers . WebSocketProvider ( 'wss ://eth- sepolia.g.alchemy.com/v2/FZDapFZSs1l6yhHW4VnQqsi18qSd-3GJ ')
15
+ const contract = new ethers . Contract ( nftAddress , nftABI , provider )
16
16
if ( ! isEventListenerCreated ) {
17
17
contract . on ( 'NFTMinted' , ( minter : string ) => {
18
18
if ( ! addressesMinted . has ( minter ) ) {
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ module.exports.contractExploitListener = function contractExploitListener () {
13
13
const metamaskAddress = req . body . walletAddress
14
14
walletsConnected . add ( metamaskAddress )
15
15
try {
16
- const provider = new ethers . WebSocketProvider ( 'wss://sepolia.infura.io/ws/v3/0b88ff4d03a647b8a4649e9bfdf6644f ' )
16
+ const provider = new ethers . WebSocketProvider ( 'wss://eth- sepolia.g.alchemy.com/v2/FZDapFZSs1l6yhHW4VnQqsi18qSd-3GJ ' )
17
17
const contract = new ethers . Contract ( web3WalletAddress , web3WalletABI , provider )
18
18
if ( ! isEventListenerCreated ) {
19
19
contract . on ( 'ContractExploited' , ( exploiter : string ) => {
You can’t perform that action at this time.
0 commit comments