fixed getter

This commit is contained in:
root 2024-09-03 20:22:14 +08:00
parent 26c2889c00
commit 52a596596f

View File

@ -144,8 +144,7 @@ app.get("/getMyTickets", async(request,response)=>{
try{ try{
const tx = await contract.getUserTickets(address); const tx = await contract.getUserTickets(address);
const receipt = await tx.wait(); response.json({ tournament_ids: tx.toString() });
response.json({ transactionHash: receipt.transactionHash });
}catch(err){ }catch(err){
console.error("Error reading tickets for user tourney:", err); console.error("Error reading tickets for user tourney:", err);
response.status(500).json({ error: err.message }); response.status(500).json({ error: err.message });