Skip to content

Commit 35cc315

Browse files
author
Sam Wierema
committed
Don't raise an AttributeError for missing attributes
The API is prone to change, but developers often forget to document these changes in the API docs, or add them to the clients. Removing this check makes the client more flexible and resistent to future changes.
1 parent 8d09d0b commit 35cc315

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

messagebird/base.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ def load(self, data):
55
for name, value in data.items():
66
if hasattr(self, name):
77
setattr(self, name, value)
8-
else:
9-
raise AttributeError("'%s' object has no attribute '%s'" % (self.__class__.__name__, name))
108

119
return self
1210

0 commit comments

Comments
 (0)