Rules refactoring
Rule refactoring