Update functions_torrent.php

This commit is contained in:
Roman Kelesidis 2023-10-24 16:22:08 +07:00
parent 27b45d6202
commit 4b4cdea802

View File

@ -275,9 +275,10 @@ function tracker_register ($attach_id, $mode = '', $tor_status = TOR_NOT_APPROVE
if ($bb_cfg['bt_check_announce_url'])
{
$announce_urls = array();
include(INC_DIR .'torrent_announce_urls.php');
$ann = (@$tor['announce']) ? $tor['announce'] : '';
$ann = (@$tor['announce']) ? strtok($tor['announce'], '?') : '';
$announce_urls['main_url'] = $bb_cfg['bt_announce_url'];
if (!$ann || !in_array($ann, $announce_urls))
@ -285,6 +286,7 @@ function tracker_register ($attach_id, $mode = '', $tor_status = TOR_NOT_APPROVE
$msg = sprintf($lang['INVALID_ANN_URL'], htmlspecialchars($ann), $announce_urls['main_url']);
torrent_error_exit($msg);
}
unset($announce_urls);
}
$info = (@$tor['info']) ? $tor['info'] : array();