Limit this to run only with the web server.
This commit is contained in:
parent
da181fc6f6
commit
767937260d
|
|
@ -107,9 +107,11 @@ class cache {
|
||||||
public function delete($key) {
|
public function delete($key) {
|
||||||
|
|
||||||
//debug information
|
//debug information
|
||||||
openlog("fusionpbx", LOG_PID | LOG_PERROR, LOG_LOCAL0);
|
if (!defined('STDIN')) {
|
||||||
syslog(LOG_WARNING, "debug: cache: [key: ".$key.", script: ".$_SERVER['SCRIPT_NAME'].", line: ".__line__."]");
|
openlog("fusionpbx", LOG_PID | LOG_PERROR, LOG_LOCAL0);
|
||||||
closelog();
|
syslog(LOG_WARNING, "debug: cache: [key: ".$key.", script: ".$_SERVER['SCRIPT_NAME'].", line: ".__line__."]");
|
||||||
|
closelog();
|
||||||
|
}
|
||||||
|
|
||||||
//cache method memcache
|
//cache method memcache
|
||||||
if ($_SESSION['cache']['method']['text'] == "memcache") {
|
if ($_SESSION['cache']['method']['text'] == "memcache") {
|
||||||
|
|
@ -173,9 +175,11 @@ class cache {
|
||||||
public function flush() {
|
public function flush() {
|
||||||
|
|
||||||
//debug information
|
//debug information
|
||||||
openlog("fusionpbx", LOG_PID | LOG_PERROR, LOG_LOCAL0);
|
if (!defined('STDIN')) {
|
||||||
syslog(LOG_WARNING, "debug: cache: [flush: all, script: ".$_SERVER['SCRIPT_NAME'].", line: ".__line__."]");
|
openlog("fusionpbx", LOG_PID | LOG_PERROR, LOG_LOCAL0);
|
||||||
closelog();
|
syslog(LOG_WARNING, "debug: cache: [flush: all, script: ".$_SERVER['SCRIPT_NAME'].", line: ".__line__."]");
|
||||||
|
closelog();
|
||||||
|
}
|
||||||
|
|
||||||
//cache method memcache
|
//cache method memcache
|
||||||
if ($_SESSION['cache']['method']['text'] == "memcache") {
|
if ($_SESSION['cache']['method']['text'] == "memcache") {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue