This commit is contained in:
Rachid Mrad 2024-04-30 20:56:24 -04:00
parent a1c5b48f03
commit 8d98434352
No known key found for this signature in database

View file

@ -244,7 +244,7 @@ function checkToListThenInitWidget(toListId, attempts) {
attempts++; attempts++;
if (attempts < 12) { if (attempts < 12) {
if ((toList && toList !== undefined)) { if (toList) {
// toList found, handle it // toList found, handle it
// Then get fromList and handle it // Then get fromList and handle it
initializeWidgetOnList(toList, ".selector-chosen"); initializeWidgetOnList(toList, ".selector-chosen");
@ -252,7 +252,7 @@ function checkToListThenInitWidget(toListId, attempts) {
initializeWidgetOnList(fromList, ".selector-available"); initializeWidgetOnList(fromList, ".selector-available");
} else { } else {
// Element not found, check again after a delay // Element not found, check again after a delay
setTimeout(() => checkToListThenInitWidget(toListId, attempts), 300); // Check every 1000 milliseconds (1 second) setTimeout(() => checkToListThenInitWidget(toListId, attempts), 300); // Check every 300 milliseconds
} }
} }
} }