-
Couldn't load subscription status.
- Fork 11
fix(connect): omit extraneous fields during connect config validation #1538
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
Conversation
this also prevents extraneous fields from migrating from myservers.cfg
WalkthroughThe Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant ConfigPersister
participant Validator
User->>ConfigPersister: Provide config object
ConfigPersister->>Validator: validateOrReject(config, { whitelist: true })
Validator-->>ConfigPersister: Validated config (unknown fields stripped)
ConfigPersister-->>User: Return validated config or throw error
Estimated code review effort2 (~15 minutes) Possibly related PRs
Suggested reviewers
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (2)
📓 Path-based instructions (1)api/**/*📄 CodeRabbit Inference Engine (.cursor/rules/api-rules.mdc)
Files:
🧠 Learnings (3)📓 Common learningsapi/dev/configs/connect.json (2)Learnt from: elibosley Learnt from: pujitm packages/unraid-api-plugin-connect/src/config/config.persistence.ts (3)Learnt from: pujitm Learnt from: pujitm Learnt from: pujitm 🧰 Additional context used📓 Path-based instructions (1)api/**/*📄 CodeRabbit Inference Engine (.cursor/rules/api-rules.mdc)
Files:
🧠 Learnings (3)📓 Common learningsapi/dev/configs/connect.json (2)Learnt from: elibosley Learnt from: pujitm packages/unraid-api-plugin-connect/src/config/config.persistence.ts (3)Learnt from: pujitm Learnt from: pujitm Learnt from: pujitm ⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
🔇 Additional comments (3)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
|
This plugin has been deployed to Cloudflare R2 and is available for testing. |
🤖 I have created a release *beep* *boop* --- ## [4.11.0](v4.10.0...v4.11.0) (2025-07-28) ### Features * tailwind v4 ([#1522](#1522)) ([2c62e0a](2c62e0a)) * **web:** install and configure nuxt ui ([#1524](#1524)) ([407585c](407585c)) ### Bug Fixes * add missing breakpoints ([#1535](#1535)) ([f5352e3](f5352e3)) * border color incorrect in tailwind ([#1544](#1544)) ([f14b74a](f14b74a)) * **connect:** omit extraneous fields during connect config validation ([#1538](#1538)) ([45bd736](45bd736)) * **deps:** pin dependencies ([#1528](#1528)) ([a74d935](a74d935)) * **deps:** pin dependency @nuxt/ui to 3.2.0 ([#1532](#1532)) ([8279531](8279531)) * **deps:** update all non-major dependencies ([#1510](#1510)) ([1a8da6d](1a8da6d)) * **deps:** update all non-major dependencies ([#1520](#1520)) ([e2fa648](e2fa648)) * inject Tailwind CSS into client entry point ([#1537](#1537)) ([86b6c4f](86b6c4f)) * make settings grid responsive ([#1463](#1463)) ([9dfdb8d](9dfdb8d)) * **notifications:** gracefully handle & mask invalid notifications ([#1529](#1529)) ([05056e7](05056e7)) * truncate log files when they take up more than 5mb of space ([#1530](#1530)) ([0a18b38](0a18b38)) * use async for primary file read/writes ([#1531](#1531)) ([23b2b88](23b2b88)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
🤖 I have created a release *beep* *boop* --- ## [4.11.0](v4.10.0...v4.11.0) (2025-07-28) ### Features * tailwind v4 ([#1522](#1522)) ([2c62e0a](2c62e0a)) * **web:** install and configure nuxt ui ([#1524](#1524)) ([407585c](407585c)) ### Bug Fixes * add missing breakpoints ([#1535](#1535)) ([f5352e3](f5352e3)) * border color incorrect in tailwind ([#1544](#1544)) ([f14b74a](f14b74a)) * **connect:** omit extraneous fields during connect config validation ([#1538](#1538)) ([45bd736](45bd736)) * **deps:** pin dependencies ([#1528](#1528)) ([a74d935](a74d935)) * **deps:** pin dependency @nuxt/ui to 3.2.0 ([#1532](#1532)) ([8279531](8279531)) * **deps:** update all non-major dependencies ([#1510](#1510)) ([1a8da6d](1a8da6d)) * **deps:** update all non-major dependencies ([#1520](#1520)) ([e2fa648](e2fa648)) * inject Tailwind CSS into client entry point ([#1537](#1537)) ([86b6c4f](86b6c4f)) * make settings grid responsive ([#1463](#1463)) ([9dfdb8d](9dfdb8d)) * **notifications:** gracefully handle & mask invalid notifications ([#1529](#1529)) ([05056e7](05056e7)) * truncate log files when they take up more than 5mb of space ([#1530](#1530)) ([0a18b38](0a18b38)) * use async for primary file read/writes ([#1531](#1531)) ([23b2b88](23b2b88)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Prevent extraneous fields from migrating to
connect.jsonfrommyservers.cfgSummary by CodeRabbit
Chores
Refactor