正在显示
1 个修改的文件
包含
15 行增加
和
6 行删除
| @@ -462,12 +462,21 @@ class Mail { | @@ -462,12 +462,21 @@ class Mail { | ||
| 462 | 462 | ||
| 463 | 463 | ||
| 464 | // 更新描述 | 464 | // 更新描述 |
| 465 | - $db->update(listsSql::$table,[ | ||
| 466 | - 'description' => $description, | ||
| 467 | - 'is_file' => MailFun::isBodyFile($body) | ||
| 468 | - ],dbWhere([ | ||
| 469 | - 'id' => $id | ||
| 470 | - ])); | 465 | + try { |
| 466 | + $db->update(listsSql::$table,[ | ||
| 467 | + 'description' => @base64_encode($description) ? $description : '', | ||
| 468 | + 'is_file' => MailFun::isBodyFile($body) | ||
| 469 | + ],dbWhere([ | ||
| 470 | + 'id' => $id | ||
| 471 | + ])); | ||
| 472 | + }catch (\Throwable $e){ | ||
| 473 | + $db->update(listsSql::$table,[ | ||
| 474 | + 'is_file' => MailFun::isBodyFile($body) | ||
| 475 | + ],dbWhere([ | ||
| 476 | + 'id' => $id | ||
| 477 | + ])); | ||
| 478 | + } | ||
| 479 | + | ||
| 471 | } | 480 | } |
| 472 | 481 | ||
| 473 | return true; | 482 | return true; |
-
请 注册 或 登录 后发表评论