This is to help solve the invalid parent issue.