Fixed bugs caused by rename