Also remove the last entry of the select

This commit is contained in:
DeionSi 2023-01-12 22:20:23 +01:00
parent f1aa431d5a
commit 07caef4707
1 changed files with 1 additions and 1 deletions

View File

@ -49,7 +49,7 @@ function refreshSerialPorts()
select = document.getElementById('portsSelect');
//Clear the current options
for (i = 0; i <= select.options.length; i++)
while (select.options.length)
{
select.remove(0); //Always 0 index (As each time an item is removed, everything shuffles up 1 place)
}