mirror of
https://github.com/Fechin/reference.git
synced 2026-11-20 21:23:11 +03:00
Update python.md
'dict' object has no attribute 'message'
This commit is contained in:
1 parent
423fab8bda
commit
d2e2f2ec09
1 file changed
+1
-1
@@ -1513,7 +1513,7 @@ def is_success(value) -> bool:
|
||||
return value in (0, "OK", True, "success")
|
||||
|
||||
resp = dict(code=0, message="OK", data=[])
|
||||
successed: bool = converter(resp.message, mapper=is_success, default=False)
|
||||
successed: bool = converter(resp["message"], mapper=is_success, default=False)
|
||||
```
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user