fix(settings): merge defaults into stored settings to fix options pag… - #1371
Conversation
…e crash (#1370) Deep-merge the default configuration into stored settings when loading them on the options page and in the content script, and restore the defaults merge on background load removed in 82047c6. Newly added nested settings (e.g. videosPerRow.videosPerRow) are now always populated, preventing the NumberInput 'Cannot read properties of undefined' crash that stopped the options page from opening.
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
WalkthroughSettings retrieval now deep-merges stored values with default configuration values. Default values also initialize at startup, with failures logged to the console. ChangesSettings defaults and loading
Estimated code review effort: 2 (Simple) | ~10 minutes Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
🎉 This PR is included in version 1.34.1 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
…e crash (#1370)
Deep-merge the default configuration into stored settings when loading them on the options page and in the content script, and restore the defaults merge on background load removed in 82047c6. Newly added nested settings (e.g. videosPerRow.videosPerRow) are now always populated, preventing the NumberInput 'Cannot read properties of undefined' crash that stopped the options page from opening.
Summary by CodeRabbit