]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
vdrive.py: let put_file return the URI that was used for the file itself
authorBrian Warner <warner@lothar.com>
Tue, 24 Apr 2007 08:41:40 +0000 (01:41 -0700)
committerBrian Warner <warner@lothar.com>
Tue, 24 Apr 2007 08:41:40 +0000 (01:41 -0700)
src/allmydata/vdrive.py

index fb2756992c43566cc38abff45d0da3329d4417fd..5b9146d06f64957408d99de9ed7c8a2c499ac961 100644 (file)
@@ -85,7 +85,9 @@ class VDrive(service.MultiService):
         def _got_dir(dirnode):
             d1 = ul.upload(uploadable)
             def _add(uri):
-                return dirnode.callRemote("add_file", name, uri)
+                d2 = dirnode.callRemote("add_file", name, uri)
+                d2.addCallback(lambda res: uri)
+                return d2
             d1.addCallback(_add)
             return d1
         d.addCallback(_got_dir)