// Add DESC keyword to executeS() filter #PSFV-791
This commit is contained in:
+1
-1
@@ -465,7 +465,7 @@ abstract class DbCore
|
|||||||
$sql = $sql->build();
|
$sql = $sql->build();
|
||||||
|
|
||||||
// This method must be used only with queries which display results
|
// This method must be used only with queries which display results
|
||||||
if (!preg_match('#^\s*\(?\s*(select|show|explain|describe)\s#i', $sql))
|
if (!preg_match('#^\s*\(?\s*(select|show|explain|describe|desc)\s#i', $sql))
|
||||||
{
|
{
|
||||||
if (defined('_PS_MODE_DEV_') && _PS_MODE_DEV_)
|
if (defined('_PS_MODE_DEV_') && _PS_MODE_DEV_)
|
||||||
throw new PrestaShopDatabaseException('Db->executeS() must be used only with select, show, explain or describe queries');
|
throw new PrestaShopDatabaseException('Db->executeS() must be used only with select, show, explain or describe queries');
|
||||||
|
|||||||
Reference in New Issue
Block a user