abderbejaoui commented on code in PR #38490:
URL: https://github.com/apache/superset/pull/38490#discussion_r3531230222


##########
superset-frontend/src/features/databases/DatabaseModal/index.tsx:
##########
@@ -415,6 +416,15 @@ export function dbReducer(
           [action.payload.name]: action.payload.checked,
         };
       }
+      if (action.payload.name === 'cache_timeout') {
+        const val = Number(action.payload.value);
+        return {
+          ...trimmedState,
+          cache_timeout: Number.isNaN(val)
+            ? undefined
+            : String(Math.max(-1, val)),
+        };
+      }

Review Comment:
   Addressed in 19a8c26 — added dbReducer tests: InputChange stores 
cache_timeout, allowing -1 (bypass cache) and InputChange clears cache_timeout 
back to unset on empty input. Resolving.



-- 
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