derailed 2020-02-07 07:21:21 -08:00
parent 12e59b4a83
commit 5b707c656e
1 changed files with 3 additions and 0 deletions

View File

@ -310,6 +310,9 @@ func (b *Browser) switchNamespaceCmd(evt *tcell.EventKey) *tcell.EventKey {
auth, err := b.App().factory.Client().CanI(ns, b.GVR(), client.MonitorAccess)
if !auth {
if err == nil {
err = fmt.Errorf("current user can't access namespace %s", ns)
}
b.App().Flash().Err(err)
return nil
}