Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions superset-frontend/src/explore/components/SaveModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -169,9 +169,8 @@ class SaveModal extends Component<SaveModalProps, SaveModalState> {
handleRedirect = (windowLocationSearch: string, chart: any) => {
const searchParams = new URLSearchParams(windowLocationSearch);
searchParams.set('save_action', this.state.action);
if (this.state.action !== 'overwrite') {
searchParams.delete('form_data_key');
}

searchParams.delete('form_data_key');

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just double-checking. If we now remove this always, is there any intended functionality that we are going to lose?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just double-checking. If we now remove this always, is there any intended functionality that we are going to lose?

Good question!
Previously, the cached form_data_key could sometimes reference an outdated datasource, causing charts to show stale data after saving changes.
By always removing it, we make sure the chart reloads from the database and reflects the most up-to-date state.
The only minor trade-off is a slightly slower load, but it ensures full data consistency


searchParams.set('slice_id', chart.id.toString());
return searchParams;
Expand Down
Loading