add missing helper function