0
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2024-12-22 08:21:52 +00:00

Downgrade directory not found and permissions errors to warnings.

Signed-off-by: Edward Z. Yang <edwardzyang@thewritingpot.com>
This commit is contained in:
Edward Z. Yang 2009-02-02 10:08:37 -05:00
parent 0c9dc02d4a
commit 1b962e68f0

View File

@ -114,7 +114,7 @@ class HTMLPurifier_DefinitionCache_Serializer extends
if (!is_dir($base)) {
trigger_error('Base directory '.$base.' does not exist,
please create or change using %Cache.SerializerPath',
E_USER_ERROR);
E_USER_WARNING);
return false;
} elseif (!$this->_testPermissions($base)) {
return false;
@ -139,7 +139,7 @@ class HTMLPurifier_DefinitionCache_Serializer extends
// generally, you'll want to handle this beforehand
// so a more specific error message can be given
trigger_error('Directory '.$dir.' does not exist',
E_USER_ERROR);
E_USER_WARNING);
return false;
}
if (function_exists('posix_getuid')) {
@ -157,12 +157,12 @@ class HTMLPurifier_DefinitionCache_Serializer extends
}
trigger_error('Directory '.$dir.' not writable, '.
'please chmod to ' . $chmod,
E_USER_ERROR);
E_USER_WARNING);
} else {
// generic error message
trigger_error('Directory '.$dir.' not writable, '.
'please alter file permissions',
E_USER_ERROR);
E_USER_WARNING);
}
return false;
}