bito-code-review[bot] commented on code in PR #38393:
URL: https://github.com/apache/superset/pull/38393#discussion_r2882830078
##########
superset-frontend/src/explore/actions/exploreActions.ts:
##########
@@ -153,6 +153,19 @@ export function setForceQuery(force: boolean) {
};
}
+export const UPDATE_EXPLORE_CHART_STATE = 'UPDATE_EXPLORE_CHART_STATE';
+export function updateExploreChartState(
+ chartId: number,
+ chartState: Record<string, unknown>,
+) {
+ return {
+ type: UPDATE_EXPLORE_CHART_STATE,
+ chartId,
+ chartState,
+ lastModified: Date.now(),
+ };
+}
Review Comment:
<div>
<div id="suggestion">
<div id="issue"><b>Missing Action Export</b></div>
<div id="fix">
The newly added updateExploreChartState action follows the correct Redux
pattern but is missing from the exploreActions object. This inconsistency could
prevent the action from being available when importing from exploreActions,
potentially causing runtime errors if code relies on that export.
</div>
<details>
<summary>
<b>Code suggestion</b>
</summary>
<blockquote>Check the AI-generated fix before applying</blockquote>
<div id="code">
```
- updateChartTitle,
- createNewSlice,
+ updateChartTitle,
+ updateExploreChartState,
+ createNewSlice,
```
</div>
</details>
</div>
<small><i>Code Review Run #a38ff4</i></small>
</div>
---
Should Bito avoid suggestions like this for future reviews? (<a
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
- [ ] Yes, avoid them
--
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]