Skip to content

Commit 556b387

Browse files
authored
fix: prevent kwargs modification during for loop iteration (#685)
1 parent 4eaa09f commit 556b387

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

interactions/api/models/misc.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ def __init__(self, **kwargs):
3636
# for key in kwargs:
3737
# setattr(self, key, kwargs[key])
3838

39-
for key in kwargs:
39+
for key in list(kwargs):
4040
if key in self.__slots__ if hasattr(self, "__slots__") else True:
4141
# else case if the mixin is used outside of this library and/or SDK.
4242
setattr(self, key, kwargs[key])

0 commit comments

Comments
 (0)