Commit e55f9e9f by Taylor Otwell

Added a helpful comment regarding expressions.

parent 19339650
......@@ -142,6 +142,9 @@ class Connection {
*/
public function query($sql, $bindings = array())
{
// Since expressions are injected into the query as raw strings, we need
// to remove them from the array of bindings. They are not truly bound
// to the PDO statement as named parameters.
foreach ($bindings as $key => $value)
{
if ($value instanceof Expression) unset($bindings[$key]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment