fix pm counter bug