Collection referrer never receives his share, collectionReferrerShare is sent to mint referrer
Summary
When "Work" tokens are minted in Edition contract, FeeManager is responsible to distribute the fee across all the parties.
But a mistake is made in the _splitProtocolFee function, where the collectionReferrerShare is sent to the mint referrer not to the collection referrer.
FeeManager.createRoute function specifies who is going to receive the fee and who is going to receive the collection referral fee when Work tokens are minted.
Brenzee
medium
Collection referrer never receives his share,
collectionReferrerShare
is sent to mint referrerSummary
When "Work" tokens are minted in
Edition
contract,FeeManager
is responsible to distribute the fee across all the parties.But a mistake is made in the
_splitProtocolFee
function, where thecollectionReferrerShare
is sent to the mint referrer not to the collection referrer.Vulnerability Detail
When Edition is created in the
TitlesCore
contract,FeeManager.createRoute
is called.FeeManager.createRoute
function specifies who is going to receive the fee and who is going to receive the collection referral fee when Work tokens are minted.But whenever Work tokens are minted in
Edition
contract, collection referral fee is sent to mint referrer rather than to collection referrer.Impact
Collection referrer will never receive the collection referrer share.
Code Snippet
FeeManager._splitProtocolFee
Tool used
Manual Review
Recommendation
Make sure that the
collectionReferrerShare
is sent to the collection referrer. Example: