mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Add getter and change visibility for whitelist_array property
This commit is contained in:
parent
d740998463
commit
80e4886c3f
@ -32,7 +32,6 @@ abstract class Database
|
||||
* 'SELECT "Version" FROM "SiteTree_Live" WHERE "ID" = ?' => 'full_query',
|
||||
* ])
|
||||
* </code>
|
||||
* @internal
|
||||
* @var array
|
||||
*/
|
||||
protected static $whitelist_array = [];
|
||||
@ -266,7 +265,7 @@ abstract class Database
|
||||
* @param mixed $query
|
||||
* @param float $endtime
|
||||
*/
|
||||
private function displayQuery($query, $endtime)
|
||||
protected function displayQuery($query, $endtime)
|
||||
{
|
||||
$queryCount = sprintf("%04d", $this->queryCount);
|
||||
Debug::message("\n$queryCount: $query\n{$endtime}s\n", false);
|
||||
@ -282,6 +281,16 @@ abstract class Database
|
||||
self::$whitelist_array = $whitelistArray;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the sql queries that need to be partially or fully matched
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function getWhitelistQueryArray()
|
||||
{
|
||||
return self::$whitelist_array;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the autogenerated ID from the previous INSERT query.
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user