portainer/portainer

View on GitHub
api/docker/images/digest.go

Summary

Maintainability
A
1 hr
Test Coverage

Method DigestClient.RemoteDigest has 5 return statements (exceeds 4 allowed).
Open

func (c *DigestClient) RemoteDigest(image Image) (digest.Digest, error) {
    ctx, cancel := c.timeoutContext()
    defer cancel()
    // Docker references with both a tag and digest are currently not supported
    if image.Tag != "" && image.Digest != "" {
Severity: Major
Found in api/docker/images/digest.go - About 35 mins to fix

    Function ParseLocalImage has 5 return statements (exceeds 4 allowed).
    Open

    func ParseLocalImage(inspect types.ImageInspect) (*Image, error) {
        if IsLocalImage(inspect) || IsDanglingImage(inspect) {
            return nil, errors.New("the image is not regular")
        }
    
    
    Severity: Major
    Found in api/docker/images/digest.go - About 35 mins to fix

      There are no issues that match your filters.

      Category
      Status