Fix items_behind error when moving a change

When moving an item, we correctly reparented the items behind
the item to the item that was previously ahead.  But we did
not remove the references to the items behind from the item
that was being moved.  This could result in that item
maintaining references to items that were previously behind it.
Generally, these would be the same and it would manifest as
double entries in items_behind.

Change-Id: Ibc1447867df4c6fc7b4fe954770a06c7c24fadc4
This commit is contained in:
James E. Blair 2013-09-20 11:40:17 -07:00
parent 0b584a9664
commit 0045126c38
1 changed files with 1 additions and 0 deletions

View File

@ -435,6 +435,7 @@ class ChangeQueue(object):
item_behind.item_ahead = item.item_ahead
# Add to new location
item.item_ahead = item_ahead
item.items_behind = []
if item.item_ahead:
item.item_ahead.items_behind.append(item)
return True