Skip to content

Commit 3f33cad

Browse files
fix: allowlist use content created at instead of list itself (#3703)
* fix: allowlist use content created at instead of list itself * fix: copy pasta error
1 parent 38510ac commit 3f33cad

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

cmd/crowdsec-cli/cliallowlists/allowlists.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,12 +209,13 @@ func (cli *cliAllowLists) listContentHuman(out io.Writer, allowlist *models.GetA
209209
})
210210

211211
for _, content := range allowlist.Items {
212+
createdAt := time.Time(content.CreatedAt).Format(time.RFC3339)
212213
expiration := "never"
213214
if !time.Time(content.Expiration).IsZero() {
214215
expiration = content.Expiration.String()
215216
}
216217

217-
contentTable.AppendRow(table.Row{content.Value, content.Description, expiration, allowlist.CreatedAt})
218+
contentTable.AppendRow(table.Row{content.Value, content.Description, expiration, createdAt})
218219
}
219220

220221
fmt.Fprintln(out, infoTable.Render())

0 commit comments

Comments
 (0)