Пример #1
0
 def _purgeemptydicts(self):
     for keys, value in list(recurse_dict_empty(self._keyword_dict)):
         if isinstance(value, dict) and not value:
             keywordDict = self._keyword_dict
             for key in keys[:-1]:
                 keywordDict = keywordDict[key]
             keywordDict.pop(keys[-1])
Пример #2
0
    def keywordItems(self):

        for keys, value in recurse_dict_empty(self._keyword_dict):
            yield value