Fix filtering for queue and running jobs