refactor, simplify usage