- some code simplifications based of review feedback