mirror of
https://github.com/e107inc/e107.git
synced 2025-07-31 03:40:37 +02:00
Issue 500 header if Captcha image fails.
This commit is contained in:
@@ -571,9 +571,10 @@ function update_core_database($type = '')
|
|||||||
|
|
||||||
// add common video and audio media categories if missing.
|
// add common video and audio media categories if missing.
|
||||||
$count = $sql->select("core_media_cat","*","media_cat_category = '_common_video' LIMIT 1 ");
|
$count = $sql->select("core_media_cat","*","media_cat_category = '_common_video' LIMIT 1 ");
|
||||||
|
|
||||||
if(!$count)
|
if(!$count)
|
||||||
{
|
{
|
||||||
if ($type !== 'do') return update_needed('Media-Manager is missing the video and audio categories and needs to be updated.');
|
if ($just_check) return update_needed('Media-Manager is missing the video and audio categories and needs to be updated.');
|
||||||
|
|
||||||
$sql->gen("INSERT INTO `".MPREFIX."core_media_cat` VALUES(0, '_common', '_common_video', '(Common Videos)', '', 'Media in this category will be available in all areas of admin. ', 253, '', 0);");
|
$sql->gen("INSERT INTO `".MPREFIX."core_media_cat` VALUES(0, '_common', '_common_video', '(Common Videos)', '', 'Media in this category will be available in all areas of admin. ', 253, '', 0);");
|
||||||
$sql->gen("INSERT INTO `".MPREFIX."core_media_cat` VALUES(0, '_common', '_common_audio', '(Common Audio)', '', 'Media in this category will be available in all areas of admin. ', 253, '', 0);");
|
$sql->gen("INSERT INTO `".MPREFIX."core_media_cat` VALUES(0, '_common', '_common_audio', '(Common Audio)', '', 'Media in this category will be available in all areas of admin. ', 253, '', 0);");
|
||||||
|
@@ -265,7 +265,9 @@ class secure_image
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
||||||
echo "Render Failed";
|
echo "Render Failed";
|
||||||
|
http_response_code(500);
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -23,6 +23,7 @@
|
|||||||
*/
|
*/
|
||||||
// error_reporting(E_ALL);
|
// error_reporting(E_ALL);
|
||||||
// define('e107_INIT', true);
|
// define('e107_INIT', true);
|
||||||
|
$_E107 = array();
|
||||||
$_E107['no_online'] = true;
|
$_E107['no_online'] = true;
|
||||||
$_E107['no_forceuserupdate'] = true;
|
$_E107['no_forceuserupdate'] = true;
|
||||||
$_E107['no_menus'] = true;
|
$_E107['no_menus'] = true;
|
||||||
|
Reference in New Issue
Block a user