Clean up the types a bit