LP lock creation silently ignores the beneficiary override field
Débutant
buggood first issuefrontendMaybe RewardedGrantFox OSSThird Campaign
0 ★
Poids du clone léger
Mise à jour
Description
## Summary
`src/components/locks/CreateLpLockForm.tsx` renders a "Beneficiary (optional)" input (`beneficiaryOverride` state, lines 336-343) with its own Address Book picker and validation styling, but the value is never actually used anywhere else in the file.
## Problem
`confirmLock()` hard-codes `beneficiary: address!` when calling `createLpLock` (line 167), and the `ConfirmLockModal` preview data also hard-codes `beneficiary: address!` (line 467). A user who types a different beneficiary address believes they are locking LP tokens for someone else, but the lock is always created with the connected wallet as beneficiary — their input is silently discarded with no error or warning.
## Task
Thread `beneficiaryOverride` through to both the actual contract call and the confirmation preview: use `beneficiaryOverride.trim() || address!` in place of the hard-coded `address!` at both line 167 and line 467, and include it in the form's validity check.
## Acceptance Criteria
- [ ] Entering a beneficiary address in the LP lock form actually locks the tokens for that address
- [ ] The confirmation modal preview shows the entered beneficiary, not always the connected wallet
- [ ] Leaving the field blank still defaults to the connected wallet
Issues similaires
Tout voir
TypeScript
Débutant
[Good First Issue] 🐡 Add new Japan Fact 251 - Beginner-Friendly Open-source Contribution
## 🟢 Good First Issue: Add Japan Fact #251 — Beginner-Friendly Open Source Contribution ![Time: <1 minute](h…
Mise à jour
TypeScript
Débutant
Error bucketing
It would be great to bucket the errors in different types i.e. Code exception, configuration exception, envir…
Mise à jour
TypeScript
Débutant
LP lock links omit the /token|lp/ URL segment, causing wrong-type lookups on the detail page
## Summary Lock detail links should include the lock's kind in the URL, e.g. `/app/lock/lp/:id` or `/app/loc…
Mise à jour