traderjoe-xyz / joe-core

📝 Main contracts for Trader Joe
MIT License
155 stars 86 forks source link

sJoe #25

Closed LouisMeMyself closed 2 years ago

LouisMeMyself commented 2 years ago

sJoe is a contract that allows to deposit moJoe and receives stable coin sent by JoeMakerV4's daily harvests. Users deposit moJoe and receive a share of what has been sent by JoeMakerV4 based on their participation of the total deposited moJoe.

jummy123 commented 2 years ago

Should there be a method to withdraw just the accumulated balance of the reward token claimReward. Right now it looks like the only way to claim rewards is either depositing or withdrawing. I can imagine a case where I want to take the reward now but leave my moJoe staking.

jummy123 commented 2 years ago

The logic of the contract LGTM :+1:

LouisMeMyself commented 2 years ago

(for jumbo's comment on adding a ClaimReward) To claim rewards without withdrawing anything, you call withdraw(0), this is how masterChef does it

LouisMeMyself commented 2 years ago

Too complicated