fixed infinite query logging until removeQuery