Skip to content

Commit ad3e088

Browse files
committed
fix is_a to instanceof
1 parent 87af5f8 commit ad3e088

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

system/Database/BaseConnection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1243,7 +1243,7 @@ public function escape($str)
12431243
}
12441244

12451245
if (is_string($str) || (is_object($str) && method_exists($str, '__toString'))) {
1246-
if (is_a($str, RawSql::class)) {
1246+
if ($str instanceof RawSql) {
12471247
return $str->__toString();
12481248
}
12491249

system/Database/Postgre/Connection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ public function escape($str)
182182
}
183183

184184
if (is_string($str) || (is_object($str) && method_exists($str, '__toString'))) {
185-
if (is_a($str, RawSql::class)) {
185+
if ($str instanceof RawSql) {
186186
return $str->__toString();
187187
}
188188

0 commit comments

Comments
 (0)