fix: handle null values in instance configuration patch endpoint#9238
fix: handle null values in instance configuration patch endpoint#9238okxint wants to merge 1 commit into
Conversation
When request.data contains None values, str(None) would produce the string "None" instead of clearing the field. This adds explicit null checking so None values become empty strings.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughIn ChangesConfiguration Value Normalization
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 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 |
What
When patching instance configuration values via the PATCH endpoint,
request.datacan containNonefor fields that should be cleared. Callingstr(None)produces the literal string"None"instead of an empty string, which gets persisted as the field value.Fix
Added an explicit null check before coercing to string:
Nonevalues now become""(empty string) as expected.Files changed
apps/api/plane/license/api/views/configuration.pySummary by CodeRabbit