feat(registry): configurable protocol-fee recipient (#99) - #226
Conversation
…k#99) Closes Stellar-VaultLink#99 - Add Registry::get_fee_recipient and Registry::set_fee_recipient, admin-gated and stored in instance storage, defaulting to the admin. - Emit a fee_rcpt governance event when the recipient changes. - Wire Repayment to route fee transfers to registry.get_fee_recipient() instead of always using the primary admin signer. - Add registry tests for default, set/get, and unauthorized access.
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Team Run ID: Note
|
samjay8
left a comment
There was a problem hiding this comment.
🤖 Auto-merge bot —
Please request assignment before opening a PR. Maintainers assign issues to avoid duplicate work and ensure quality review.
Once assigned, this PR will be re-evaluated automatically.
samjay8
left a comment
There was a problem hiding this comment.
🤖 Auto-merge bot — ❌ CI failed. What broke:
- Soroban Scout (
failure)
(no details — see the check log)
Please fix and push — I will re-check automatically.
samjay8
left a comment
There was a problem hiding this comment.
🤖 Auto-merge bot — ✅ All required CI checks and the CodeRabbit review passed.
This PR accomplishes:
- set_fee_recipient(address) is admin-gated (same threshold pattern as set_fee) and emits a ee_rcpt governance event.
- get_fee_recipient() returns the configured address, defaulting to the admin for existing deployments.
- Repayment now routes fee transfers to
egistry.get_fee_recipient() instead of always using the primary admin signer.
Diff: the diff — verified within scope.
CI is green — merging now.
samjay8
left a comment
There was a problem hiding this comment.
🤖 Approved — all required CI checks and the CodeRabbit review passed.
|
🎉 Merged — thanks for the contribution! |
Closes #99
Adds a configurable protocol-fee recipient address to the Registry contract:
egistry.get_fee_recipient() instead of always using the primary admin signer.
Fee rate and collection math are unchanged per the issue scope.
cargo test -p invofi-registry and cargo build --workspace pass.