Skip to content

Commit

Permalink
Skip CLI session expired notifcation if notifications are disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
lixmal committed Feb 1, 2025
1 parent 19e2499 commit 1836fdf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion client/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -766,10 +766,11 @@ func (s *Server) GetConfig(_ context.Context, _ *proto.GetConfigRequest) (*proto
DisableNotifications: s.config.DisableNotifications,
}, nil
}

func (s *Server) onSessionExpire() {
if runtime.GOOS != "windows" {
isUIActive := internal.CheckUIApp()
if !isUIActive {
if !isUIActive && !s.config.DisableNotifications {
if err := sendTerminalNotification(); err != nil {
log.Errorf("send session expire terminal notification: %v", err)
}
Expand Down

0 comments on commit 1836fdf

Please sign in to comment.