()
| 372 | ) |
| 373 | |
| 374 | func (d *detector) ProjectsV1() gh.ProjectsV1Support { |
| 375 | if !ghauth.IsEnterprise(d.host) { |
| 376 | return gh.ProjectsV1Unsupported |
| 377 | } |
| 378 | |
| 379 | hostVersion, hostVersionErr := resolveEnterpriseVersion(d.client(), d.host) |
| 380 | v1ProjectCutoffVersion, v1ProjectCutoffVersionErr := version.NewVersion(enterpriseProjectsV1Removed) |
| 381 | |
| 382 | if hostVersionErr == nil && v1ProjectCutoffVersionErr == nil && hostVersion.LessThan(v1ProjectCutoffVersion) { |
| 383 | return gh.ProjectsV1Supported |
| 384 | } |
| 385 | |
| 386 | return gh.ProjectsV1Unsupported |
| 387 | } |
| 388 | |
| 389 | func (d *detector) ProjectFeatures() (ProjectFeatures, error) { |
| 390 | if !ghauth.IsEnterprise(d.host) { |
nothing calls this directly
no test coverage detected