Manual rebase of the invalid queue redirect

Better check for null queue.