queue fixed some bugs