couple of micro code refactor