Skip to content

ContainerFormat's CreatedAt has wrong documentation #2413

@diamondo25

Description

@diamondo25

// CreatedAt returns the "Created" date/time of the container as a unix timestamp.
func (c *ContainerContext) CreatedAt() string {
return time.Unix(c.c.Created, 0).String()
}

time.Unix().String() will not create a unix timestamp (number), but instead will create an string as explained in the documentation: https://golang.org/pkg/time/#Time.String .

Maybe add another variant, eg CreatedAtTimestamp to support this option nonetheless.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions