Removed buggy queue class & fixed bugs