def setData(self, data): Account.setData(self, data) for attr in ('email',): try: setattr(self, attr, data[attr]) except KeyError: pass
def setData(self, data): Account.setData(self, data) for attr in ('email', ): try: setattr(self, attr, data[attr]) except KeyError: pass
def setData(self, data): Account.setData(self, data) for attr in ("email",): if attr not in data: continue setattr(self, attr, data[attr])