Skip to content

Commit 6c0b6ce

Browse files
committed
fix: Fixed deepscan issues
Signed-off-by: Hrishav <[email protected]>
1 parent c92c4b3 commit 6c0b6ce

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

chaoscenter/web/src/components/YAMLBuilder/YAMLBuilder.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ function YAMLBuilder(props: YAMLBuilderProps): React.ReactElement {
4949
debounce((updatedYaml: string): void => {
5050
setCurrentYaml(updatedYaml);
5151
currentYamlRef.current = updatedYaml;
52-
onChangeRef.current?.(!(updatedYaml === ''), updatedYaml);
52+
onChangeRef.current?.(updatedYaml !== '', updatedYaml);
5353
}, 500),
5454
[onChangeRef]
5555
);

chaoscenter/web/src/views/ExperimentYAMLBuilder/ExperimentYAMLBuilder.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ function ExperimentYamlBuilderView({ setError, setHasFaults }: ExperimentYamlBui
4646
params: error.params ?? {}
4747
};
4848
});
49-
const hasErrors = !(errors === undefined);
49+
const hasErrors = errors !== undefined;
5050
// if errors are there open editor in edit mode
5151
hasErrors && setIsEditEnabled(true);
5252
// set errors to disable navigation to visual tab and save button

0 commit comments

Comments
 (0)