Skip to content

Commit a0fd22f

Browse files
committed
Merge pull request laravel#772 from loic-sharma/patch-3
Fixed bug where the profiler did not correctly put quotes around bindings
2 parents 01f8323 + f2e915f commit a0fd22f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

laravel/profiling/profiler.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
use Laravel\Event;
66
use Laravel\Config;
77
use Laravel\Request;
8+
use Laravel\Database;
89

910
class Profiler {
1011

@@ -57,6 +58,8 @@ public static function query($sql, $bindings, $time)
5758
{
5859
foreach ($bindings as $binding)
5960
{
61+
$binding = Database::connection()->pdo->quote($binding);
62+
6063
$sql = preg_replace('/\?/', $binding, $sql, 1);
6164
}
6265

0 commit comments

Comments
 (0)