Update selected code flow when data flow paths change (#2288)

This commit is contained in:
Charis Kyriakou
2023-04-11 11:02:03 +01:00
committed by GitHub
parent 0115259778
commit deb2b83642
2 changed files with 6 additions and 0 deletions

View File

@@ -2,6 +2,7 @@
## [UNRELEASED]
- Fix bug that was causing code flows to not get updated when switching between results. [#2288](https://github.com/github/vscode-codeql/pull/2288)
- Restart the CodeQL language server whenever the _CodeQL: Restart Query Server_ command is invoked. This avoids bugs where the CLI version changes to support new language features, but the language server is not updated. [#2238](https://github.com/github/vscode-codeql/pull/2238)
## 1.8.1 - 23 March 2023

View File

@@ -41,6 +41,11 @@ export const DataFlowPaths = ({
const { codeFlows, ruleDescription, message, severity } = dataFlowPaths;
React.useEffect(() => {
// Make sure to update the selected code flow if the data flow paths change
setSelectedCodeFlow(dataFlowPaths.codeFlows[0]);
}, [dataFlowPaths]);
return (
<>
<VerticalSpace size={2} />