finally fixed renaming bug