[GeneralDiscussion] applied to unstable: be more careful when mutating the parents property, to avoid inconsistencies (#1353, Willi Langenberger)
[email protected] (unstable-repo)
| Newsgroups | gmane.comp.web.zope.zwiki |
|---|---|
| Message-ID | <20080502040245.50D0A465DCD__9767.11956686831$1209701025$gmane$org@mail.joyful.com> |
Thu May 1 21:00:59 PDT 2008 [email protected] * be more careful when mutating the parents property, to avoid inconsistencies (#1353, Willi Langenberger) diff -rN -u old-ZWiki-unstable/OutlineSupport.py new-ZWiki-unstable/OutlineSupport.py --- old-ZWiki-unstable/OutlineSupport.py 2008-05-01 21:02:44.000000000 -0700 +++ new-ZWiki-unstable/OutlineSupport.py 2008-05-01 21:02:44.000000000 -0700 @@ -157,10 +157,13 @@ if parent and not parent in self.parents: self.ensureParentsPropertyIsList() self.parents.append(parent) + self._p_changed = 1 def removeParent(self,parent): self.ensureParentsPropertyIsList() - try: self.parents.remove(parent) + try: + self.parents.remove(parent) + self._p_changed = 1 except ValueError: BLATHER("failed to remove %s from %s's parents (%s)" \ % (parent,self.getId(),self.parents)) -- forwarded from http://zwiki.org/GeneralDiscussion#[email protected]