/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/revisiontree.py

  • Committer: John Arbash Meinel
  • Date: 2009-03-25 16:27:34 UTC
  • mto: This revision was merged to the branch mainline in revision 4204.
  • Revision ID: john@arbash-meinel.com-20090325162734-ugfiu6gxisdc2m4p
Update Repository.iter_files_bytes() to return an iterable of bytestrings.
Several places in the code expected it to return exactly a string, so these have
been updated as well.

Show diffs side-by-side

added added

removed removed

Lines of Context:
64
64
        return self._revision_id
65
65
 
66
66
    def get_file_text(self, file_id, path=None):
67
 
        return list(self.iter_files_bytes([(file_id, None)]))[0][1]
 
67
        _, content = list(self.iter_files_bytes([(file_id, None)]))[0]
 
68
        return ''.join(content)
68
69
 
69
70
    def get_file(self, file_id, path=None):
70
71
        return StringIO(self.get_file_text(file_id))