Fix bugs with QueueAdapter where removing the last item from the user queue or the next queue would cause weird behavior or a crash.
Fix bugs with QueueAdapter where removing the last item from the user queue or the next queue would cause weird behavior or a crash.