Skip to content

Fix update_info behavior to preserve appliance_id on partial API errors#44

Closed
alexskr wants to merge 1 commit intoontoportal:masterfrom
ncbo:fix-update-info-error-handling
Closed

Fix update_info behavior to preserve appliance_id on partial API errors#44
alexskr wants to merge 1 commit intoontoportal:masterfrom
ncbo:fix-update-info-error-handling

Conversation

@alexskr
Copy link
Contributor

@alexskr alexskr commented Apr 2, 2025

  • Refactored update_info method to always assign @update_info, even if the API response includes an "error" key.
  • Ensured that partial failures (e.g., update check error) do not prevent access to valid fields like appliance_id.
  • Updated method to use a keyword argument (render_response: true) instead of a positional boolean, improving readability and satisfying Rubocop guidelines.

- Refactored `update_info` method to always assign @update_info, even if the API response includes an "error" key.
- Ensured that partial failures (e.g., update check error) do not prevent access to valid fields like appliance_id.
- Updated method to use a keyword argument (`render_response: true`) instead of a positional boolean, improving readability and satisfying Rubocop guidelines.
@alexskr
Copy link
Contributor Author

alexskr commented Apr 2, 2025

wrong repo

@alexskr alexskr closed this Apr 2, 2025
@alexskr alexskr deleted the fix-update-info-error-handling branch April 2, 2025 20:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant