1
0
Fork 0
mirror of https://github.com/Oreolek/ifhub.club.git synced 2024-05-19 09:18:18 +03:00

fix database sql

This commit is contained in:
Mzhelskiy Maxim 2011-08-21 16:48:52 +00:00
parent 786127b070
commit 04db5e2f8c

View file

@ -188,7 +188,7 @@ class ModuleDatabase extends Module {
*/
public function isFieldExists($sTableName,$sFieldName,$aConfig=null) {
$sTableName = str_replace('prefix_', Config::Get('db.table.prefix'), $sTableName);
$sQuery="SHOW FIELDS FROM '{$sTableName}'";
$sQuery="SHOW FIELDS FROM `{$sTableName}`";
if ($aRows=$this->GetConnect($aConfig)->select($sQuery)) {
foreach ($aRows as $aRow){
if ($aRow['Field'] == $sFieldName){