mirror of
https://github.com/LiteyukiStudio/LiteyukiBot.git
synced 2024-11-22 21:27:43 +08:00
🐛 orm框架在解析字段值时遇到None报错的问题
This commit is contained in:
parent
1b283261c3
commit
4cd7b6718b
@ -155,7 +155,7 @@ class Database:
|
||||
|
||||
if field.startswith(self.BYTES_PREFIX):
|
||||
|
||||
new_obj[field.replace(self.BYTES_PREFIX, "")] = self._load(pickle.loads(value))
|
||||
new_obj[field.replace(self.BYTES_PREFIX, "")] = self._load(pickle.loads(value) if value else value) # 从value字段可能为None,fix at 2024/6/13
|
||||
|
||||
elif field.startswith(self.FOREIGN_KEY_PREFIX):
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user