forked from blallo/rss-bridge
Merge pull request #233 from teromene/master
Added an URL option to activate debug :
This commit is contained in:
commit
b2f42144f8
2 changed files with 9 additions and 2 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -226,3 +226,4 @@ pip-log.txt
|
||||||
##############
|
##############
|
||||||
/cache
|
/cache
|
||||||
/whitelist.txt
|
/whitelist.txt
|
||||||
|
DEBUG
|
||||||
|
|
10
index.php
10
index.php
|
@ -14,7 +14,13 @@ TODO :
|
||||||
|
|
||||||
date_default_timezone_set('UTC');
|
date_default_timezone_set('UTC');
|
||||||
error_reporting(0);
|
error_reporting(0);
|
||||||
//ini_set('display_errors','1'); error_reporting(E_ALL); // For debugging only.
|
|
||||||
|
if(file_exists("DEBUG")) {
|
||||||
|
|
||||||
|
ini_set('display_errors','1'); error_reporting(E_ALL); //Report all errors
|
||||||
|
define("DEBUG", "true");
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
require_once __DIR__ . '/lib/RssBridge.php';
|
require_once __DIR__ . '/lib/RssBridge.php';
|
||||||
|
|
||||||
|
@ -84,7 +90,7 @@ try{
|
||||||
|
|
||||||
// Data retrieval
|
// Data retrieval
|
||||||
$bridge = Bridge::create($bridge);
|
$bridge = Bridge::create($bridge);
|
||||||
if(isset($_REQUEST["disable_cache"])) {
|
if(defined("DEBUG")) {
|
||||||
} else {
|
} else {
|
||||||
$bridge->setCache($cache); // just add disable cache to your query to disable caching
|
$bridge->setCache($cache); // just add disable cache to your query to disable caching
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue