Skip to content

Commit 501e168

Browse files
authored
Merge pull request #20273 from FRRouting/mergify/bp/stable/10.4/pr-20268
bgpd: correction in json output structure for no data case (backport #20268)
2 parents f467e95 + 71c54fa commit 501e168

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

bgpd/bgp_evpn_vty.c

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3331,13 +3331,9 @@ static void evpn_show_vni(struct vty *vty, struct bgp *bgp, vni_t vni,
33313331
}
33323332
}
33333333

3334-
if (!found) {
3335-
if (json) {
3336-
vty_out(vty, "{}\n");
3337-
} else {
3338-
vty_out(vty, "VNI not found\n");
3339-
return;
3340-
}
3334+
if (!found && !json) {
3335+
vty_out(vty, "VNI not found\n");
3336+
return;
33413337
}
33423338
}
33433339

0 commit comments

Comments
 (0)