fix the bug the getParent