refactored to create_with_parent