refactoring.
This commit is contained in:
@@ -87,7 +87,7 @@ class Connection {
|
||||
{
|
||||
$result = (array) $this->first($sql, $bindings);
|
||||
|
||||
return (strpos(strtolower($sql), 'select count') === 0) ? (int) reset($result) : (float) reset($result);
|
||||
return (strpos(strtolower(trim($sql)), 'select count') === 0) ? (int) reset($result) : (float) reset($result);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -7,11 +7,6 @@ class Postgres extends Query {
|
||||
/**
|
||||
* Insert an array of values into the database table and return the value of the ID column.
|
||||
*
|
||||
* <code>
|
||||
* // Insert into the "users" table and get the auto-incrementing ID
|
||||
* $id = DB::table('users')->insert_get_id(array('email' => 'example@gmail.com'));
|
||||
* </code>
|
||||
*
|
||||
* @param array $values
|
||||
* @return int
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user