Fix bug in Downloader's _get_local_latest
authorDavid Stainton <dstainton415@gmail.com>
Sat, 12 Sep 2015 14:52:26 +0000 (16:52 +0200)
committerDavid Stainton <dstainton415@gmail.com>
Sat, 12 Sep 2015 14:52:26 +0000 (16:52 +0200)
previously the magic-folder path was not prepended
to the file path... thus the file didn't exist and
the call to _get_local_latest returned None.

src/allmydata/frontends/magic_folder.py

index 062cb04ebf6d970669f176f1a1fe5677647f3598..479884047165668b3855626586f21cf916ad170d 100644 (file)
@@ -436,7 +436,7 @@ class Downloader(QueueMixin):
         exists in our magic-folder db; if not then return None
         else check for an entry in our magic-folder db and return the version number.
         """
-        if not os.path.exists(path_u):
+        if not os.path.exists(os.path.join(self._local_path_u,path_u)):
             return None
         return self._db.get_local_file_version(path_u)