Fix GET-FOREGROUND in case there is only one interactive thread