fix(EditFlowSettingsComponent): fix issue with invalidName state not updating correctly when input value is changed
This commit is contained in:
parent
a64ee239de
commit
758d5ac9d3
1 changed files with 8 additions and 7 deletions
|
|
@ -36,15 +36,16 @@ export const EditFlowSettings: React.FC<InputProps> = ({
|
|||
}
|
||||
if (invalidName !== undefined) {
|
||||
if (!nameLists.current.includes(value)) {
|
||||
setInvalidName(false);
|
||||
setInvalidName!(false);
|
||||
} else {
|
||||
setInvalidName(true);
|
||||
setInvalidName!(true);
|
||||
}
|
||||
|
||||
if (!nameLists.current.includes(value)) {
|
||||
setInvalidName!(false);
|
||||
} else {
|
||||
setInvalidName!(true);
|
||||
}
|
||||
}
|
||||
if (!nameLists.current.includes(value)) {
|
||||
setInvalidName!(false);
|
||||
} else {
|
||||
setInvalidName!(true);
|
||||
}
|
||||
setName(value);
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue