Skip to content
Snippets Groups Projects
Commit 57fb1692 authored by Himanen, Lauri (himanel1)'s avatar Himanen, Lauri (himanel1)
Browse files

Fixed bug/typo in caching_backend.py: CachingSection.__getitem__()

parent 05634268
No related branches found
No related tags found
No related merge requests found
......@@ -34,14 +34,16 @@ class CachingSection(object):
self.storeInSuper = storeInSuper
def __getitem__(self, metaName):
"""Returns the cached values corresponding to metaName, or None if there aren't any"""
"""Returns the cached values corresponding to metaName, or None if
there aren't any. You can search values and subsections.
"""
res = self.simpleValues.get(metaName, None)
if res:
return res
res = arrayValues.arrayValues.get(metaName, None)
res = self.arrayValues.get(metaName, None)
if res:
return res
res = subSectionValues.get(metaName, None)
res = self.subSectionValues.get(metaName, None)
return res
def addValue(self, metaInfo, value):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment