~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/inventory.py

  • Committer: John Arbash Meinel
  • Date: 2006-08-30 13:54:51 UTC
  • mto: This revision was merged to the branch mainline in revision 1975.
  • Revision ID: john@arbash-meinel.com-20060830135451-db085d993f76f572
change return foo in bar to return (foo in bar)

Show diffs side-by-side

added added

removed removed

Lines of Context:
325
325
 
326
326
    @staticmethod
327
327
    def versionable_kind(kind):
328
 
        return kind in ('file', 'directory', 'symlink')
 
328
        return (kind in ('file', 'directory', 'symlink'))
329
329
 
330
330
    def check(self, checker, rev_id, inv, tree):
331
331
        """Check this inventory entry is intact.
1017
1017
        >>> '456' in inv
1018
1018
        False
1019
1019
        """
1020
 
        return file_id in self._byid
 
1020
        return (file_id in self._byid)
1021
1021
 
1022
1022
    def __getitem__(self, file_id):
1023
1023
        """Return the entry for given file_id.
1215
1215
        return bool(self.path2id(names))
1216
1216
 
1217
1217
    def has_id(self, file_id):
1218
 
        return file_id in self._byid
 
1218
        return (file_id in self._byid)
1219
1219
 
1220
1220
    def rename(self, file_id, new_parent_id, new_name):
1221
1221
        """Move a file within the inventory.