~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/uncommit.py

  • Committer: Aaron Bentley
  • Date: 2007-07-11 14:58:54 UTC
  • mto: This revision was merged to the branch mainline in revision 2606.
  • Revision ID: abentley@panoramicfeedback.com-20070711145854-06486yosdvexapy1
Got all tests passing with Branch returning 'null:' for null revision

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
 
21
21
import os
22
22
 
 
23
from bzrlib import revision as _mod_revision
23
24
from bzrlib.branch import Branch
24
25
from bzrlib.errors import BoundBranchOutOfDate
25
26
 
84
85
                hook_local = branch
85
86
                hook_master = master
86
87
            for hook in Branch.hooks['post_uncommit']:
 
88
                hook_new_tip = new_tip
 
89
                if hook_new_tip == _mod_revision.NULL_REVISION:
 
90
                    hook_new_tip = None
87
91
                hook(hook_local, hook_master, old_revno, old_tip, new_revno,
88
 
                    new_tip)
 
92
                     hook_new_tip)
89
93
            if tree is not None:
90
 
                if new_tip is not None:
 
94
                if not _mod_revision.is_null(new_tip):
91
95
                    parents = [new_tip]
92
96
                else:
93
97
                    parents = []