Fix empty birthday list.

This commit is contained in:
Yuriy Pikhtarev 2017-06-22 23:02:11 +03:00
commit 0c09d969b0
No known key found for this signature in database
GPG key ID: 3A9B5A757B48ECC6
3 changed files with 4 additions and 4 deletions

View file

@ -372,7 +372,7 @@ if ($bb_cfg['birthday_check_day'] && $bb_cfg['birthday_enabled']) {
$week_list = $today_list = array();
$week_all = $today_all = false;
if (isset($stats['birthday_week_list'])) {
if (!empty($stats['birthday_week_list'])) {
shuffle($stats['birthday_week_list']);
foreach ($stats['birthday_week_list'] as $i => $week) {
if ($i >= 5) {
@ -387,7 +387,7 @@ if ($bb_cfg['birthday_check_day'] && $bb_cfg['birthday_enabled']) {
$week_list = sprintf($lang['NOBIRTHDAY_WEEK'], $bb_cfg['birthday_check_day']);
}
if (isset($stats['birthday_today_list'])) {
if (!empty($stats['birthday_today_list'])) {
shuffle($stats['birthday_today_list']);
foreach ($stats['birthday_today_list'] as $i => $today) {
if ($i >= 5) {

View file

@ -104,7 +104,7 @@ $bb_cfg['server_port'] = (!empty($_SERVER['SERVER_PORT'])) ? $_SERVER['SERVER_PO
$bb_cfg['script_path'] = '/'; // The path where FORUM is located relative to the domain name
// GZip
$bb_cfg['gzip_compress'] = true; // compress output
$bb_cfg['gzip_compress'] = false; // compress output
// Tracker
$bb_cfg['announce_interval'] = 2400; // Announce interval (default: 1800)

View file

@ -46,7 +46,7 @@ if ($logged_in) {
// Online userlist
if (defined('SHOW_ONLINE') && SHOW_ONLINE) {
$online_full = !empty($_REQUEST['online_full']);
$online_list = ($online_full) ? 'online_' . $userdata['user_lang'] : 'online_short_' . $userdata['user_lang'];
$online_list = $online_full ? 'online_' . $userdata['user_lang'] : 'online_short_' . $userdata['user_lang'];
${$online_list} = array(
'stat' => '',