[gnome-shell] workspacesView: Handle null return value



commit 46b0d3f6cc4a0a74cb6362c9cf27315900d2e40c
Author: Florian Müllner <fmuellner gnome org>
Date:   Fri Aug 13 02:52:09 2021 +0200

    workspacesView: Handle null return value
    
    We are not going to process key events while updating views,
    but coverity complains (CID 351269)...
    
    Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>

 js/ui/workspacesView.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/js/ui/workspacesView.js b/js/ui/workspacesView.js
index 1d03e31319..3761881d01 100644
--- a/js/ui/workspacesView.js
+++ b/js/ui/workspacesView.js
@@ -1019,7 +1019,7 @@ class WorkspacesDisplay extends St.Widget {
     }
 
     vfunc_navigate_focus(from, direction) {
-        return this._getPrimaryView().navigate_focus(from, direction, false);
+        return this._getPrimaryView()?.navigate_focus(from, direction, false);
     }
 
     setPrimaryWorkspaceVisible(visible) {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]