fixed some errors due to merge