mirror of
https://github.com/fluxcd/flux2.git
synced 2026-02-21 23:21:48 +00:00
cmd/events: handle error value
Signed-off-by: Hidde Beydals <hidde@hhh.computer>
This commit is contained in:
parent
8214fefde6
commit
2a033215a4
1 changed files with 3 additions and 0 deletions
|
|
@ -127,6 +127,9 @@ func eventsCmdRun(cmd *cobra.Command, args []string) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
rows, err := getRows(ctx, kubeclient, clientListOpts, refListOpts, showNamespace)
|
rows, err := getRows(ctx, kubeclient, clientListOpts, refListOpts, showNamespace)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
if len(rows) == 0 {
|
if len(rows) == 0 {
|
||||||
if eventArgs.allNamespaces {
|
if eventArgs.allNamespaces {
|
||||||
logger.Failuref("No events found.")
|
logger.Failuref("No events found.")
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue