NautilusPlugin: Fix detection of top level sync folder.
authorKlaas Freitag <freitag@owncloud.com>
Wed, 25 Nov 2015 12:32:41 +0000 (13:32 +0100)
committerKlaas Freitag <freitag@owncloud.com>
Wed, 25 Nov 2015 14:11:12 +0000 (15:11 +0100)
shell_integration/nautilus/syncstate.py

index 17cb492ae3240adf6b60e27930d489db5d870ee8..01761ec4ba711f595551de36f77aaf147ca8bbcb 100755 (executable)
@@ -169,7 +169,7 @@ class MenuExtension(GObject.GObject, Nautilus.MenuProvider):
             if os.path.isdir(filename + "/"):
                 filename += "/"
                 # Check if toplevel folder, we need to ignore those as they cannot be shared
-                if filename.count("/") < (reg_path.count("/")+2):
+                if filename == reg_path:
                     topLevelFolder=True                
             # Only show the menu extension if the file is synced and the sync
             # status is ok. Not for ignored files etc.