Skip to content

Commit

Permalink
Switch from preg_split to explode for DB::replace_parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxime Rainville committed Sep 23, 2018
1 parent dd436f5 commit 07f9cdc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ORM/DB.php
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ public static function inline_parameters($sql, $parameters)
*/
public static function replace_parameter($sql, $paramIdx, $replacement, $skipEscaping = false)
{
$segments = preg_split('/\?/', $sql);
$segments = explode('?', $sql);
$joined = '';
$inString = false;
$numSegments = count($segments);
Expand Down

0 comments on commit 07f9cdc

Please sign in to comment.