Refactor cruft