We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 90bd0b8 commit c3465e5Copy full SHA for c3465e5
system/Database/BaseBuilder.php
@@ -14,6 +14,7 @@
14
use Closure;
15
use CodeIgniter\Database\Exceptions\DatabaseException;
16
use CodeIgniter\Database\Exceptions\DataException;
17
+use CodeIgniter\Database\RawSql;
18
use InvalidArgumentException;
19
20
/**
@@ -2698,7 +2699,7 @@ protected function objectToArray($object)
2698
2699
2700
foreach (get_object_vars($object) as $key => $val) {
2701
// There are some built in keys we need to ignore for this conversion
- if (! is_object($val) && ! is_array($val) && $key !== '_parent_name') {
2702
+ if ((! is_object($val) && ! is_array($val) && $key !== '_parent_name') || is_a($val, RawSql::class)) {
2703
$array[$key] = $val;
2704
}
2705
0 commit comments