Skip to content
Permalink
Browse files

Add Driver::disableAutoQuoting().

  • Loading branch information...
ADmad committed Nov 1, 2018
1 parent 631e7df commit 2ca0486539b47fc1f1702efe59c6e13ecf49940f
Showing with 16 additions and 1 deletion.
  1. +13 −0 src/Database/Driver.php
  2. +2 −0 src/Database/DriverInterface.php
  3. +1 −1 tests/TestCase/Database/DriverTest.php
@@ -362,6 +362,19 @@ public function enableAutoQuoting($enable = true)
return $this;
}
/**
* Disable auto quoting of identifiers in queries.
*
* @return $this
*/
public function disableAutoQuoting()
{
$this->_autoQuoting = false;
return $this;
}
/**
* {@inheritDoc}
*/
@@ -18,6 +18,8 @@
/**
* Interface for database driver.
*
* @method $this disableAutoQuoting()
*/
interface DriverInterface
{
@@ -198,7 +198,7 @@ public function testAutoQuoting()
$this->assertSame($this->driver, $this->driver->enableAutoQuoting(true));
$this->assertTrue($this->driver->isAutoQuotingEnabled());
$this->driver->enableAutoQuoting(false);
$this->driver->disableAutoQuoting();
$this->assertFalse($this->driver->isAutoQuotingEnabled());
$this->driver->enableAutoQuoting('string');

0 comments on commit 2ca0486

Please sign in to comment.
You can’t perform that action at this time.