consolidate functionality