Need to fix bug in popoing and queue right direction