Skip to content
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

ProtocolFeeSplitter factory default #2133

Open
wants to merge 31 commits into
base: master
Choose a base branch
from

Conversation

EndymionJkb
Copy link
Collaborator

Description

Allow setting a default revenue share per factory, in addition to per pool. Since pool types are very different, so a single default revenue share is not the best solution. Having defaults per factory avoids having to set overrides on every single pool.

The logic is then straightforward. If there is an override share percentage set on a pool, it will use that. Otherwise, if there are factory defaults and the pool was deployed from one of them, use the factory default. Otherwise, fall back on the "global" default revenue share.

This PR is based from the "sentinel" PR (#2131), as it extends this logic.

Type of change

  • Bug fix
  • New feature
  • Breaking change
  • Dependency changes
  • Code refactor / cleanup
  • Documentation or wording changes
  • Other

Checklist:

  • The diff is legible and has no extraneous changes
  • Complex code has been commented, including external interfaces
  • Tests are included for all code paths
  • The base branch is either master, or there's a description of how to merge

Issue Resolution

Resolves #2050

@EndymionJkb EndymionJkb changed the title Splitter factory default ProtocolFeeSplitter factory default Dec 10, 2022
Base automatically changed from splitter-sentinel to master December 13, 2022 02:57
# Conflicts:
#	pkg/interfaces/contracts/standalone-utils/IProtocolFeeSplitter.sol
#	pkg/standalone-utils/contracts/ProtocolFeeSplitter.sol
#	pkg/standalone-utils/test/ProtocolFeeSplitter.test.ts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant