]> dgit.raspbian.org Git - nextcloud-desktop.git/commitdiff
Nautilus plugin: Be more robust against new states from socketapi
authorKlaas Freitag <freitag@owncloud.com>
Wed, 20 Apr 2016 15:13:06 +0000 (17:13 +0200)
committerKlaas Freitag <freitag@owncloud.com>
Wed, 20 Apr 2016 15:13:06 +0000 (17:13 +0200)
Do not bail out if an unknown state comes from SocketApi

shell_integration/nautilus/syncstate.py

index 63ebae5864846071efb4fac958c3253b6c301a11..9dcfec746b8825d4a9ac4f1a6e202252c145d7ef 100644 (file)
@@ -249,7 +249,9 @@ class SyncStateExtension(GObject.GObject, Nautilus.ColumnProvider, Nautilus.Info
         # print("Action for " + file + ": " + args[0])  # For debug only
         if action == 'STATUS':
             newState = args[0]
-            emblem = Emblems[newState]
+            emblem = 'NOP' # Show nothing if no emblem si defined.
+            if newState in Emblems:
+                emblem = Emblems[newState]
             filename = ':'.join(args[1:])
 
             if emblem: