fix some bugs after adding classes