mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-06 03:50:04 +02:00
Update
This commit is contained in:
parent
7695fd0fee
commit
a843d34bcb
2 changed files with 8 additions and 3 deletions
|
@ -1113,6 +1113,7 @@ abstract class CacheHandler {
|
||||||
TimeLogStart($timeLog);
|
TimeLogStart($timeLog);
|
||||||
$prefix = $this->getCacheSubdir();
|
$prefix = $this->getCacheSubdir();
|
||||||
if (class_exists('CachesInDB')) {
|
if (class_exists('CachesInDB')) {
|
||||||
|
_error_log("deleteCache CachesInDB");
|
||||||
CacheDB::deleteCacheStartingWith($prefix);
|
CacheDB::deleteCacheStartingWith($prefix);
|
||||||
}
|
}
|
||||||
TimeLogEnd($timeLog, __LINE__);
|
TimeLogEnd($timeLog, __LINE__);
|
||||||
|
@ -1121,6 +1122,7 @@ abstract class CacheHandler {
|
||||||
unset($_SESSION['user']['sessionCache']);
|
unset($_SESSION['user']['sessionCache']);
|
||||||
TimeLogEnd($timeLog, __LINE__);
|
TimeLogEnd($timeLog, __LINE__);
|
||||||
if($clearFirstPageCache){
|
if($clearFirstPageCache){
|
||||||
|
_error_log("deleteCache clearFirstPageCache");
|
||||||
clearCache(true);
|
clearCache(true);
|
||||||
}
|
}
|
||||||
TimeLogEnd($timeLog, __LINE__);
|
TimeLogEnd($timeLog, __LINE__);
|
||||||
|
|
|
@ -335,13 +335,16 @@ class CachesInDB extends ObjectYPT
|
||||||
public static function _deleteCacheStartingWith($name)
|
public static function _deleteCacheStartingWith($name)
|
||||||
{
|
{
|
||||||
if(isBot()){
|
if(isBot()){
|
||||||
|
_error_log("CachesInDB::_deleteCacheStartingWith($name) error line=".__LINE__);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
global $global;
|
global $global;
|
||||||
if (empty($name)) {
|
if (empty($name)) {
|
||||||
|
_error_log("CachesInDB::_deleteCacheStartingWith($name) error line=".__LINE__);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (!static::isTableInstalled()) {
|
if (!static::isTableInstalled()) {
|
||||||
|
_error_log("CachesInDB::_deleteCacheStartingWith($name) error line=".__LINE__);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
$name = self::hashName($name);
|
$name = self::hashName($name);
|
||||||
|
@ -349,7 +352,7 @@ class CachesInDB extends ObjectYPT
|
||||||
//$sql = "DELETE FROM " . static::getTableName() . " WHERE name LIKE '{$name}%'";
|
//$sql = "DELETE FROM " . static::getTableName() . " WHERE name LIKE '{$name}%'";
|
||||||
$sql = "DELETE FROM " . static::getTableName() . " WHERE MATCH(name) AGAINST('{$name}*' IN BOOLEAN MODE);";
|
$sql = "DELETE FROM " . static::getTableName() . " WHERE MATCH(name) AGAINST('{$name}*' IN BOOLEAN MODE);";
|
||||||
|
|
||||||
_error_log("CachesInDB::_deleteCacheStartingWith($name)($name) $sql");
|
_error_log("CachesInDB::_deleteCacheStartingWith($name) $sql");
|
||||||
$global['lastQuery'] = $sql;
|
$global['lastQuery'] = $sql;
|
||||||
//_error_log("Delete Query: ".$sql);
|
//_error_log("Delete Query: ".$sql);
|
||||||
self::readUncomited();
|
self::readUncomited();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue