* baseDAO: fix error can't set cache for the updated table.
This commit is contained in:
@@ -991,6 +991,8 @@ class baseDAO
|
||||
/* Real-time save log. */
|
||||
if(dao::$realTimeLog && dao::$realTimeFile) file_put_contents(dao::$realTimeFile, $sql . "\n", FILE_APPEND);
|
||||
|
||||
$table = $this->table;
|
||||
|
||||
$this->reset();
|
||||
|
||||
/* Force to query from master db, if db has been changed. */
|
||||
@@ -998,11 +1000,11 @@ class baseDAO
|
||||
|
||||
$result = $this->dbh->exec($sql);
|
||||
|
||||
if($this->table)
|
||||
if($table)
|
||||
{
|
||||
/* 更新表的缓存时间。*/
|
||||
/* Update the table cache time. */
|
||||
$table = str_replace(array('`', '"'), '', $this->table);
|
||||
$table = str_replace(array('`', '"'), '', $table);
|
||||
$this->setCache($table);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user