Refactoring ad shiet