Minor improvements (#798)

This commit is contained in:
Roman Kelesidis 2023-06-10 11:14:26 +07:00 committed by GitHub
commit 99602ec255
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 6 deletions

View file

@ -12,8 +12,8 @@ if (!defined('BB_ROOT')) {
} }
// Server settings // Server settings
$force_name = 'torrentpier.com'; // enter here your primary domain name of your site $force_name = 'torrentpier.com'; // The domain name from which this board runs
$force_port = 80; $force_port = 80; // The port your server is running on
$force_ssl = false; $force_ssl = false;
$bb_cfg = []; $bb_cfg = [];

View file

@ -1506,14 +1506,14 @@ function get_topic_title($topic_id)
return $row['topic_title']; return $row['topic_title'];
} }
function forum_exists($forum_id) function forum_exists($forum_id): bool
{ {
return DB()->fetch_row("SELECT forum_id FROM " . BB_FORUMS . " WHERE forum_id = $forum_id LIMIT 1"); return (bool)DB()->fetch_row("SELECT forum_id FROM " . BB_FORUMS . " WHERE forum_id = $forum_id LIMIT 1");
} }
function cat_exists($cat_id) function cat_exists($cat_id): bool
{ {
return DB()->fetch_row("SELECT cat_id FROM " . BB_CATEGORIES . " WHERE cat_id = $cat_id LIMIT 1"); return (bool)DB()->fetch_row("SELECT cat_id FROM " . BB_CATEGORIES . " WHERE cat_id = $cat_id LIMIT 1");
} }
function get_topic_icon($topic, $is_unread = null) function get_topic_icon($topic, $is_unread = null)