bugfix

corrected counting