Fix misid calulation in Kpipi