hide span when no items are available, speed up database performance for count