fixed bugs for 2.1.1