eclypse-labs / eclypse-core

The core contracts of the eclypse protocol
1 stars 0 forks source link

check pattern check-effects-interaction #18

Open GustaveCharles opened 1 year ago

GustaveCharles commented 1 year ago

Saw 1-2 problems when quick checked on this pattern, just discuss it so we know if there is a real threat. @devsquaaa @0xirons @Lolshh

gaspardthrl commented 1 year ago

imo no since it's not a rule but more a general pattern that may be use as a guideline for most functions. Sometimes, like when withdrawing here, it would be difficult to check is a position is liquidatable before actually withdrawing liquidity since the amount of tokens that are withdrawn are not fixed.

If you think any bug could arise, explain them.