You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/02/22 11:56:53 UTC

[GitHub] [superset] michael-s-molina commented on a change in pull request #18846: fix(key-value): lost url_params after long-url feature

michael-s-molina commented on a change in pull request #18846:
URL: https://github.com/apache/superset/pull/18846#discussion_r811868014



##########
File path: superset-frontend/src/explore/components/ExploreViewContainer/index.jsx
##########
@@ -175,6 +175,19 @@ const updateHistory = debounce(
       additionalParam[URL_PARAMS.datasetId.name] = datasetId;
     }
 
+    const urlParams = payload?.url_params || {};

Review comment:
       Wouldn't be cleaner to just initialize `additionalParam` with `payload?.url_params`? If some of the parameters are already in the URL they will be overridden anyway. This way you don't need the `forEach` and the `if` check.




-- 
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: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org