Refactoring on a Sunday night