Fixed bug. Forgot to increment a counter