Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../httpdocs/wp-conte.../plugins/smart-sl.../Nextend/Framewor.../Cache/Storage
File: Filesystem.php
<?php
[0] Fix | Delete
[1] Fix | Delete
[2] Fix | Delete
namespace Nextend\Framework\Cache\Storage;
[3] Fix | Delete
[4] Fix | Delete
[5] Fix | Delete
class Filesystem extends AbstractStorage {
[6] Fix | Delete
[7] Fix | Delete
public function __construct() {
[8] Fix | Delete
$this->paths['web'] = \Nextend\Framework\Filesystem\Filesystem::getWebCachePath();
[9] Fix | Delete
$this->paths['notweb'] = \Nextend\Framework\Filesystem\Filesystem::getNotWebCachePath();
[10] Fix | Delete
$this->paths['image'] = \Nextend\Framework\Filesystem\Filesystem::getImagesFolder();
[11] Fix | Delete
}
[12] Fix | Delete
[13] Fix | Delete
public function isFilesystem() {
[14] Fix | Delete
return true;
[15] Fix | Delete
}
[16] Fix | Delete
[17] Fix | Delete
public function clearAll($scope = 'notweb') {
[18] Fix | Delete
if (\Nextend\Framework\Filesystem\Filesystem::existsFolder($this->paths[$scope])) {
[19] Fix | Delete
\Nextend\Framework\Filesystem\Filesystem::deleteFolder($this->paths[$scope]);
[20] Fix | Delete
}
[21] Fix | Delete
}
[22] Fix | Delete
[23] Fix | Delete
public function clear($group, $scope = 'notweb') {
[24] Fix | Delete
[25] Fix | Delete
if (\Nextend\Framework\Filesystem\Filesystem::existsFolder($this->paths[$scope] . '/' . $group)) {
[26] Fix | Delete
\Nextend\Framework\Filesystem\Filesystem::deleteFolder($this->paths[$scope] . '/' . $group);
[27] Fix | Delete
}
[28] Fix | Delete
}
[29] Fix | Delete
[30] Fix | Delete
public function exists($group, $key, $scope = 'notweb') {
[31] Fix | Delete
if (\Nextend\Framework\Filesystem\Filesystem::existsFile($this->paths[$scope] . '/' . $group . '/' . $key)) {
[32] Fix | Delete
return true;
[33] Fix | Delete
}
[34] Fix | Delete
[35] Fix | Delete
return false;
[36] Fix | Delete
}
[37] Fix | Delete
[38] Fix | Delete
public function set($group, $key, $value, $scope = 'notweb') {
[39] Fix | Delete
$path = $this->paths[$scope] . '/' . $group . '/' . $key;
[40] Fix | Delete
$dir = dirname($path);
[41] Fix | Delete
if (!\Nextend\Framework\Filesystem\Filesystem::existsFolder($dir)) {
[42] Fix | Delete
\Nextend\Framework\Filesystem\Filesystem::createFolder($dir);
[43] Fix | Delete
}
[44] Fix | Delete
\Nextend\Framework\Filesystem\Filesystem::createFile($path, $value);
[45] Fix | Delete
}
[46] Fix | Delete
[47] Fix | Delete
public function get($group, $key, $scope = 'notweb') {
[48] Fix | Delete
return \Nextend\Framework\Filesystem\Filesystem::readFile($this->paths[$scope] . '/' . $group . '/' . $key);
[49] Fix | Delete
}
[50] Fix | Delete
[51] Fix | Delete
public function remove($group, $key, $scope = 'notweb') {
[52] Fix | Delete
if ($this->exists($group, $key, $scope)) {
[53] Fix | Delete
@unlink($this->paths[$scope] . '/' . $group . '/' . $key);
[54] Fix | Delete
}
[55] Fix | Delete
}
[56] Fix | Delete
[57] Fix | Delete
public function getPath($group, $key, $scope = 'notweb') {
[58] Fix | Delete
return $this->paths[$scope] . DIRECTORY_SEPARATOR . $group . DIRECTORY_SEPARATOR . $key;
[59] Fix | Delete
}
[60] Fix | Delete
}
[61] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function