From 76b9963893cac5a8acf6477c1a04673328562f1a Mon Sep 17 00:00:00 2001 From: XueyuanPang-Google Date: Sun, 30 Aug 2026 22:13:25 +0800 Subject: [PATCH] fix(escrow): restrict Refund sponsor button visibility to the verified bounty sponsor (#260) --- src/app/issues/[id]/IssueActions.tsx | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/app/issues/[id]/IssueActions.tsx b/src/app/issues/[id]/IssueActions.tsx index 3ceb6c7..7d960e3 100644 --- a/src/app/issues/[id]/IssueActions.tsx +++ b/src/app/issues/[id]/IssueActions.tsx @@ -128,11 +128,14 @@ export function IssueActions({ bounty }: { bounty: Bounty }) { {pending ? "Claiming..." : "Claim this issue"} )} - {(bounty.status === "funded" || bounty.status === "claimed") && ( - - )} + {(bounty.status === "funded" || bounty.status === "claimed") && + address && + bounty.sponsorAddress && + address.toLowerCase() === bounty.sponsorAddress.toLowerCase() && ( + + )} {["in_review", "merged", "paid", "refunded", "expired"].includes( bounty.status, ) && (