Improvements made thanks to the #go-nuts irc channel