Refactoring mode checker