Skip to content

Commit 7f98e44

Browse files
fix(QueryEditor): do not reset input on empty savedPath (#451)
1 parent 652c3c6 commit 7f98e44

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/containers/Tenant/Query/QueryEditor/QueryEditor.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,10 @@ function QueryEditor(props) {
104104

105105
useEffect(() => {
106106
if (savedPath !== path) {
107+
if (savedPath) {
108+
changeUserInput({input: ''});
109+
}
107110
setTenantPath(path);
108-
changeUserInput({input: ''});
109111
}
110112
}, [changeUserInput, setTenantPath, path, savedPath]);
111113

0 commit comments

Comments
 (0)