refactoring:reduce context parameters