This commit is contained in:
Roman Kelesidis 2023-12-14 16:57:22 +07:00
parent 2c4e2b3a5e
commit 2e39c35a1f
2 changed files with 19 additions and 6 deletions

View File

@ -1864,12 +1864,6 @@ function bb_die ($msg_text)
exit; exit;
} }
// Alias for bb_die()
function message_die ($msg_code, $msg_text = '')
{
bb_die($msg_text);
}
function bb_simple_die ($txt) function bb_simple_die ($txt)
{ {
global $bb_cfg; global $bb_cfg;
@ -1883,6 +1877,19 @@ function bb_simple_die ($txt)
die($txt); die($txt);
} }
// Alias for bb_die()
function message_die ($msg_code, $msg_text = '')
{
if ($msg_code == CRITICAL_MESSAGE || $msg_code == CRITICAL_ERROR)
{
bb_simple_die($msg_text);
}
else
{
bb_die($msg_text);
}
}
function bb_realpath ($path) function bb_realpath ($path)
{ {
return (!@function_exists('realpath') || !@realpath(INC_DIR . 'functions.php')) ? $path : @realpath($path); return (!@function_exists('realpath') || !@realpath(INC_DIR . 'functions.php')) ? $path : @realpath($path);

View File

@ -122,6 +122,12 @@ define('SEARCH_TYPE_TRACKER', 1);
define('E_AJAX_GENERAL_ERROR', 1000); define('E_AJAX_GENERAL_ERROR', 1000);
define('E_AJAX_NEED_LOGIN', 1001); define('E_AJAX_NEED_LOGIN', 1001);
// Error codes (Legacy)
define('GENERAL_MESSAGE', 200);
define('GENERAL_ERROR', 202);
define('CRITICAL_MESSAGE', 203);
define('CRITICAL_ERROR', 204);
// Private messaging // Private messaging
define('PRIVMSGS_READ_MAIL', 0); define('PRIVMSGS_READ_MAIL', 0);
define('PRIVMSGS_NEW_MAIL', 1); define('PRIVMSGS_NEW_MAIL', 1);