Fix error in count