replaced some self.add(key, value) as self[key] = value