Skip to content

Conversation

ajunior
Copy link
Contributor

@ajunior ajunior commented Apr 19, 2025

Add the public method IsEmpty() to check if the table has no data.

Example:

t := table.New(os.Stdout)
t.SetHeaders("Key", "Value")
t.AddRow(key, value)

if t.IsEmpty() {
    fmt.Println("No records to show")
} else {
    t.Render()
}

This PR resolves the issue #28.

@CLAassistant
Copy link

CLAassistant commented Apr 19, 2025

CLA assistant check
All committers have signed the CLA.

@owenrumney
Copy link
Contributor

LGTM, thanks @ajunior

@owenrumney owenrumney merged commit 0852ecf into aquasecurity:main Apr 28, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants