refactor isPub in arret condition