refactor/cleanup arc helper function