[FIXED JENKINS-25314]

The original fix was made in 0c3d67097a3394fee7f0eb895c4350ea96887a02.
In this fix, I'm also moving the code that creates LeftItem.

It makes no sense that there's Item.cancel(Queue) and Queue.cancel(Item)
and they do different things!
Merge commit '9b36e2ae8dbbd2a7ab0d9d4bc9e24e305e33ecbc'