Skip to content

Commit 7420a56

Browse files
committed
fix is_a to instanceof
1 parent 6601c31 commit 7420a56

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
@@ -1238,7 +1238,7 @@ public function escape($str)
12381238
}
12391239

12401240
if (is_string($str) || (is_object($str) && method_exists($str, '__toString'))) {
1241-
if (is_a($str, RawSql::class)) {
1241+
if ($str instanceof RawSql) {
12421242
return $str->__toString();
12431243
}
12441244

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)