Module refactor