Fixes some queue handling bugs. *claps*