refactor: Improve InputGlobalComponent behavior and data handling
This commit is contained in:
parent
111def3d4a
commit
64eb2e0f99
1 changed files with 3 additions and 3 deletions
|
|
@ -34,8 +34,8 @@ export default function InputGlobalComponent({
|
|||
useEffect(() => {
|
||||
if (data)
|
||||
if (
|
||||
globalVariablesEntries &&
|
||||
!globalVariablesEntries.includes(data.value) &&
|
||||
((globalVariablesEntries &&
|
||||
!globalVariablesEntries.includes(data.value))||!globalVariablesEntries) &&
|
||||
data.load_from_db
|
||||
) {
|
||||
setTimeout(() => {
|
||||
|
|
@ -43,7 +43,7 @@ export default function InputGlobalComponent({
|
|||
setDb(false);
|
||||
}, 100);
|
||||
}
|
||||
}, [globalVariablesEntries]);
|
||||
}, [globalVariablesEntries,data]);
|
||||
|
||||
useEffect(() => {
|
||||
if (!data.value && data.display_name) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue