MASTER refactoring