Skip to content
This repository has been archived by the owner on Jan 24, 2024. It is now read-only.

feat(redacted-cartel): add support for claimable rewards #2274

Merged
merged 4 commits into from
Feb 10, 2023

Conversation

0xalecks
Copy link
Contributor

Description

This replaces the current redacted-cartel revenue locked contract position. The old one was extending VotingEscrowTemplateContractPositionFetcher which does not support easily adding rewards.

This change switches the implementation to a standard ContractPositionTemplatePositionFetcher and adds support for fetching claimable rewards (from Redacted's API).

Checklist

@wpoulin
Copy link
Contributor

wpoulin commented Feb 10, 2023

Did you notice there's a VotingEscrowWithRewardsTemplateContractPositionFetcher template ?

@0xalecks
Copy link
Contributor Author

Did you notice there's a VotingEscrowWithRewardsTemplateContractPositionFetcher template ?

Ah no I didn't. Is it okay if we go forward with this, or do you want me to rewrite it using the template? Look at that template, we would've had to make some modifications anyway, since the rewards aren't getting pulled from the chain, but from an http api, so things like getRewardContract() wouldn't have mapped nicely.

@wpoulin
Copy link
Contributor

wpoulin commented Feb 10, 2023

It's ok, don't worry. Last question before I merge, is there a way to get rewards using call on chain instead of an external API?

@wpoulin wpoulin merged commit 99efbbb into Zapper-fi:main Feb 10, 2023
0xdapper pushed a commit to 0xdapper/studio that referenced this pull request Feb 28, 2023
)

* feat(redacted-cartel): remove old fetcher

* feat(redacted-cartel): add new fetcher

---------

Co-authored-by: William Poulin <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants