Skip to content

Commit fc17197

Browse files
committed
改进getChangedData方法
1 parent 9813c04 commit fc17197

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/model/concern/Attribute.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
use Closure;
1818
use InvalidArgumentException;
1919
use Stringable;
20+
use think\db\Express;
2021
use think\db\Raw;
2122
use think\helper\Str;
2223
use think\Model;
@@ -436,7 +437,7 @@ public function getChangedData(array $data = []): array
436437
return 1;
437438
}
438439

439-
if ($b instanceof Raw) {
440+
if ($b instanceof Raw || $b instanceof Express) {
440441
return 0;
441442
}
442443

0 commit comments

Comments
 (0)