Skip to content
Snippets Groups Projects
Commit e0f746a9 authored by Mohamed, Fawzi Roberto (fawzi)'s avatar Mohamed, Fawzi Roberto (fawzi)
Browse files

caching_backend: remove section only after onClose triggers

parent 80691ee7
Branches
Tags
No related merge requests found
......@@ -110,7 +110,7 @@ class CachingSectionManager(object):
self.openSections[gIndex] = CachingSection(gIndex, references, storeInSuper = self.storeInSuper)
def closeSection(self, backend, gIndex):
toClose = self.openSections.pop(gIndex)
toClose = self.openSections[-1]
for onCloseF in self.onClose:
onCloseF(backend, gIndex, toClose)
if toClose.storeInSuper:
......@@ -124,6 +124,7 @@ class CachingSectionManager(object):
backend.parsingSession.addSubsection(self.metaInfo, toClose)
if self.forwardOpenClose and backend.superBackend:
backend.superBackend.closeSection(self.metaInfo.name, gIndex)
self.openSections.remove(toClose)
def openSectionInfo(self, gIndex):
section = openSections.get(gIndex, None)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment