Bug fix when new device shows up after script was started