cache starred: only try to chmod cache directory if it is not writable
This commit is contained in:
parent
0c0e5f3640
commit
f5967cf825
|
@ -21,7 +21,9 @@ class Cache_Starred_Images extends Plugin {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (is_dir($this->cache_dir)) {
|
if (is_dir($this->cache_dir)) {
|
||||||
chmod($this->cache_dir, 0777);
|
|
||||||
|
if (!is_writable($this->cache_dir))
|
||||||
|
chmod($this->cache_dir, 0777);
|
||||||
|
|
||||||
if (is_writable($this->cache_dir)) {
|
if (is_writable($this->cache_dir)) {
|
||||||
$host->add_hook($host::HOOK_UPDATE_TASK, $this);
|
$host->add_hook($host::HOOK_UPDATE_TASK, $this);
|
||||||
|
|
Loading…
Reference in New Issue