Ensure return doesn't fail when the return value is None