code: def toggle_badge(self, kind):
          '''Toggle a bdage given its kind'''
          badge = self.get_badge(kind)
          if badge:
              return self.remove_badge(kind)
          else:
              return self.add_badge(kindf toggle_badge(self, kind):
          '''Toggle a bdage given its kind'''
          badge = self.get_badge(kind)
          if badge:
              return self.remove_badge(kind)
          else:
              return self.add_badge(kind)
docs: Toggle a bdage given its kind