fixed some bugs on Mandarine