Fix up a bunch of issues. Thanks Nick and Mark.