msyavuz commented on code in PR #37218:
URL: https://github.com/apache/superset/pull/37218#discussion_r2745450260


##########
superset-frontend/src/explore/controlUtils/getControlState.ts:
##########
@@ -122,7 +122,8 @@ export function applyMapStateToPropsToControl<T = 
ControlType>(
     }
   }
   // If no current value, set it as default
-  if (state.default && value === undefined) {
+  // Use loose equality to catch both null and undefined
+  if (state.default != null && value == null) {

Review Comment:
   This looks much cleaner, great work!



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to