bugfix: update counter