More cleanup and types.