Commit 0d9cca43 authored by Tobias Schultze's avatar Tobias Schultze

replace unneeded RegEx

parent b8033f8e
......@@ -72,8 +72,8 @@ EOT
throw new \LogicException("Option 'depth' must contains an integer value");
}
if (preg_match('/^select/i', $sql)) {
$resultSet = $conn->fetchAll($sql);
if (stripos($sql, 'select') === 0) {
$resultSet = $conn->fetchAll($sql);
} else {
$resultSet = $conn->executeUpdate($sql);
}
......
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