Redefine modes
Correct bugs
Add trim