mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-06 07:50:32 +00:00
Fix ListOfLists deserializer.
This commit is contained in:
parent
2987369925
commit
843caf51a9
1 changed files with 6 additions and 5 deletions
|
|
@ -145,11 +145,12 @@ class ListOfLists(Field):
|
|||
def deserialize(self, value, parent=None):
|
||||
result = []
|
||||
deserialize = super(ListOfLists, self).deserialize
|
||||
for row in value:
|
||||
row_result = []
|
||||
for item in row:
|
||||
row_result.append(deserialize(item, parent=parent))
|
||||
result.append(row_result)
|
||||
if hasattr(value, '__iter__'):
|
||||
for row in value:
|
||||
row_result = []
|
||||
for item in row:
|
||||
row_result.append(deserialize(item, parent=parent))
|
||||
result.append(row_result)
|
||||
return result
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue