~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/transform.py

  • Committer: Martin Pool
  • Date: 2011-06-14 02:21:41 UTC
  • mto: This revision was merged to the branch mainline in revision 6001.
  • Revision ID: mbp@canonical.com-20110614022141-18hmm7s0iw3utcbj
Deprecate __contains__ on Tree and Inventory

Show diffs side-by-side

added added

removed removed

Lines of Context:
2935
2935
                        if basis_tree is None:
2936
2936
                            basis_tree = working_tree.basis_tree()
2937
2937
                            basis_tree.lock_read()
2938
 
                        if file_id in basis_tree:
 
2938
                        if basis_tree.has_id(file_id):
2939
2939
                            if wt_sha1 != basis_tree.get_file_sha1(file_id):
2940
2940
                                keep_content = True
2941
2941
                        elif target_kind is None and not target_versioned:
2971
2971
                        basis_tree = working_tree.basis_tree()
2972
2972
                        basis_tree.lock_read()
2973
2973
                    new_sha1 = target_tree.get_file_sha1(file_id)
2974
 
                    if (file_id in basis_tree and new_sha1 ==
2975
 
                        basis_tree.get_file_sha1(file_id)):
 
2974
                    if (basis_tree.has_id(file_id) and
 
2975
                        new_sha1 == basis_tree.get_file_sha1(file_id)):
2976
2976
                        if file_id in merge_modified:
2977
2977
                            del merge_modified[file_id]
2978
2978
                    else:
3129
3129
        elif c_type == 'unversioned parent':
3130
3130
            file_id = tt.inactive_file_id(conflict[1])
3131
3131
            # special-case the other tree root (move its children instead)
3132
 
            if path_tree and file_id in path_tree:
 
3132
            if path_tree and path_tree.has_id(file_id):
3133
3133
                if path_tree.path2id('') == file_id:
3134
3134
                    # This is the root entry, skip it
3135
3135
                    continue