diff --git a/dropboxfs.py b/dropboxfs.py index df35b9d..b90c515 100644 --- a/dropboxfs.py +++ b/dropboxfs.py @@ -214,9 +214,9 @@ def __init__(self, *args, **kwargs): # metadata() and children(). This allows for more fine-grained fetches # and caching. - def metadata(self, path): + def metadata(self, path, cache_read=True): "Gets metadata for a given path." - item = self.cache.get(path) + item = self.cache.get(path) if cache_read else None if not item or item.metadata is None or item.expired: try: metadata = super(DropboxClient, self).metadata(path, @@ -455,9 +455,9 @@ def listdir(self, path="/", wildcard=None, full=False, absolute=False, dirs_only return self._listdir_helper(path, children, wildcard, full, absolute, dirs_only, files_only) @synchronize - def getinfo(self, path): + def getinfo(self, path, cache_read=True): path = abspath(normpath(path)) - metadata = self.client.metadata(path) + metadata = self.client.metadata(path, cache_read=cache_read) return metadata_to_info(metadata, localtime=self.localtime) def copy(self, src, dst, *args, **kwargs):