Fixed wrong counter in a pain-free way.