-
Notifications
You must be signed in to change notification settings - Fork 38
feat:handle protocol fee interface functions #118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
bc3dbd7
02dac22
3e986c1
fd62ce1
e7e05a1
cc1da23
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -218,6 +218,26 @@ pub trait ICampaignDonation<TContractState> { | |||||||||
| // / * Caller must have donated to the campaign | ||||||||||
| // / * Refund must not have been claimed already | ||||||||||
| fn claim_refund(ref self: TContractState, campaign_id: u256); | ||||||||||
|
|
||||||||||
| // ************************************************************************* | ||||||||||
| // PROTOCOL FEES | ||||||||||
| // ************************************************************************* | ||||||||||
|
|
||||||||||
| /// @notice Gets the current protocol fee percentage | ||||||||||
| /// @return The protocol fee percentage (100 = 1%) | ||||||||||
| fn get_protocol_fee_percent(self: @TContractState) -> u256; | ||||||||||
|
|
||||||||||
| /// @notice Sets a new protocol fee percentage | ||||||||||
| /// @param new_fee_percent The new fee percentage to set (100 = 1%) | ||||||||||
| fn set_protocol_fee_percent(ref self: TContractState, new_fee_percent: u256); | ||||||||||
|
Comment on lines
+231
to
+232
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Inconsistent fee percentage documentation The parameter documentation should also clarify the basis points format. Update the documentation: - /// @param new_fee_percent The new fee percentage to set (100 = 1%)
+ /// @param new_fee_percent The new fee percentage to set in basis points (100 = 1%, 10000 = 100%)📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||
|
|
||||||||||
| /// @notice Gets the current protocol fee collection address | ||||||||||
| /// @return The address where protocol fees are sent | ||||||||||
| fn get_protocol_fee_address(self: @TContractState) -> ContractAddress; | ||||||||||
|
|
||||||||||
| /// @notice Sets a new protocol fee collection address | ||||||||||
| /// @param new_fee_address The new address to collect protocol fees | ||||||||||
| fn set_protocol_fee_address(ref self: TContractState, new_fee_address: ContractAddress); | ||||||||||
| // ************************************************************************* | ||||||||||
| // ANALYTICS & INSIGHTS | ||||||||||
| // ************************************************************************* | ||||||||||
|
|
||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Inconsistent fee percentage documentation
The comment states "100 = 1%" but the implementation uses basis points where 100 = 1% would be represented as 100 basis points out of 10000. This should be clarified to avoid confusion.
Update the documentation to match the implementation:
📝 Committable suggestion
🤖 Prompt for AI Agents