merge wjwwood's cleanup from groovy to hydro