minor refactoring to comply with pbc