Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor logging settings to use DittoLogLevel directly #71

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

rdas-ditto
Copy link

Creating this PR to review required changes to updating the iOS demo app to work with Tools 7.1.0

  • Replaced LoggingOptions with DittoLogLevel from the Ditto SDK, removing the reference to custom wrapper type.
  • Added isLoggingEnabled state to separately track logging enablement alongside log levels.
  • Updated SettingsModel:
    • Refactored storedLoggingOption to migrate legacy UserDefaults values to DittoLogLevel and clean up old keys.
    • Simplified future storage/retrieval to use DittoLogLevel directly.
  • Modified SettingsView constructor to take a Ditto instance instead of LoggingOptions.

These changes simplify logging logic, align with the updated Ditto SDK, and ensure backward compatibility.

@rdas-ditto rdas-ditto requested a review from a team as a code owner January 16, 2025 13:54
- Replaced `LoggingOptions` with `DittoLogLevel` from the Ditto SDK, removing the reference to custom wrapper type.
- Added `isLoggingEnabled` state to separately track logging enablement alongside log levels.
- Updated `SettingsModel`:
  - Refactored `storedLoggingOption` to migrate legacy `UserDefaults` values to `DittoLogLevel` and clean up old keys.
  - Simplified future storage/retrieval to use `DittoLogLevel` directly.
- Modified `SettingsView` constructor to take a `Ditto` instance instead of `LoggingOptions`.

These changes simplify logging logic, align with the updated Ditto SDK, and ensure backward compatibility.
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