refactor params