Move the count to after where we pull out the best match