Remove any sections that have no options.
(self)
| 113 | self.add_section(section) |
| 114 | |
| 115 | def RemoveEmptySections(self): |
| 116 | "Remove any sections that have no options." |
| 117 | for section in self.sections(): |
| 118 | if not self.GetOptionList(section): |
| 119 | self.remove_section(section) |
| 120 | |
| 121 | def IsEmpty(self): |
| 122 | "Return True if no sections after removing empty sections." |