Style and error fixes

Found with `gofmt -s`, `goimports`, and `go vet`.