Fixed rename bugs