summaryrefslogtreecommitdiff
path: root/it_url.class
diff options
context:
space:
mode:
authorUrban Müller2012-01-28 11:29:05 +0000
committerUrban Müller2012-01-28 11:29:05 +0000
commit42ab3d58e5bbb624ffe57732c153bf20ae6d6e09 (patch)
tree0c6ae67784988b21d5ad1bec67acdb6c58e6a6d7 /it_url.class
parenta79e11223e6b84ceceab8657218a1b18c9233ed7 (diff)
downloaditools-42ab3d58e5bbb624ffe57732c153bf20ae6d6e09.tar.gz
itools-42ab3d58e5bbb624ffe57732c153bf20ae6d6e09.tar.bz2
itools-42ab3d58e5bbb624ffe57732c153bf20ae6d6e09.zip
honor "safety" param in it_url::get_cache_contents
Diffstat (limited to 'it_url.class')
-rw-r--r--it_url.class2
1 files changed, 1 insertions, 1 deletions
diff --git a/it_url.class b/it_url.class
index cf7f45a..753164a 100644
--- a/it_url.class
+++ b/it_url.class
@@ -584,7 +584,7 @@ function get_cache($p = array())
*/
function get_cache_contents($p)
{
- return ($fn = self::get_cache($p)) ? file_get_contents($fn) : it::error(array('title' => "failed getting " . $p['url'], 'body' => var_export($p, true)));
+ return ($fn = self::get_cache($p)) ? file_get_contents($fn) : ($p['safety'] === 0 ? null : it::error(array('title' => "failed getting " . $p['url'], 'body' => var_export($p, true))));
}
/**