Use empty() instead of count