From: Brian Warner Date: Tue, 17 Mar 2015 18:13:57 +0000 (-0700) Subject: tahoe_cp: be consistent with "source.basename() is None" testing X-Git-Tag: allmydata-tahoe-1.10.1a1~60^2~1 X-Git-Url: https://git.rkrishnan.org/frontends/install.html?a=commitdiff_plain;h=48da2cd99bca142ad52720c061f4cfb529b55a37;p=tahoe-lafs%2Ftahoe-lafs.git tahoe_cp: be consistent with "source.basename() is None" testing --- diff --git a/src/allmydata/scripts/tahoe_cp.py b/src/allmydata/scripts/tahoe_cp.py index 30892392..46244e87 100644 --- a/src/allmydata/scripts/tahoe_cp.py +++ b/src/allmydata/scripts/tahoe_cp.py @@ -559,7 +559,7 @@ class Copier: _assert(isinstance(target, DirectoryTargets + MissingTargets), target) for source in sources: - if isinstance(source, FileSources) and not source.basename(): + if isinstance(source, FileSources) and source.basename() is None: self.to_stderr("when copying into a directory, all source files must have names, but %s is unnamed" % quote_output(source_specs[0])) return 1 return self.copy_things_to_directory(sources, target)