The Pool may be in three states: Initialized, Finalized and Deactivated as indicated by the enum State variable. While a couple of functions such as fundLoan() and deposit() check against a valid Pool state i.e. Finalized using \_isValidState(State.Finalized), most other functions miss this check. This could cause unexpected protocol behavior if such functions are triggered in invalid Pool states (e.g. deactivated).
Examples of such functions missing this Pool state validity check are triggerDefault()``,claim(), withdraw()andwithdrawFunds().
Recommend adding _isValidState(State.Finalized) check to all such functions specified above.
**lucas-manuel (Maple) acknowledged.
Nick Johnson (Judge):
satyamakgec (Maple) commented:
