remove duplicated commands from queue