Refactoring error mechanism