mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-22 06:13:58 -07:00
Minor improvements (#1294)
This commit is contained in:
parent
09f352d2dd
commit
1a3bdf171e
1 changed files with 7 additions and 7 deletions
14
posting.php
14
posting.php
|
@ -247,6 +247,13 @@ if ($mode == 'new_rel') {
|
|||
exit;
|
||||
}
|
||||
|
||||
// Disallowed release editing with a certain status
|
||||
if (!empty($bb_cfg['tor_cannot_edit']) && $post_info['allow_reg_tracker'] && $post_data['first_post'] && !IS_AM) {
|
||||
if ($tor_status = DB()->fetch_row("SELECT tor_status FROM " . BB_BT_TORRENTS . " WHERE topic_id = $topic_id AND forum_id = $forum_id AND tor_status IN(" . implode(',', $bb_cfg['tor_cannot_edit']) . ") LIMIT 1")) {
|
||||
bb_die($lang['NOT_EDIT_TOR_STATUS'] . ': <span title="' . $lang['TOR_STATUS_NAME'][$tor_status['tor_status']] . '">' . $bb_cfg['tor_icons'][$tor_status['tor_status']] . ' ' . $lang['TOR_STATUS_NAME'][$tor_status['tor_status']] . '</span>.');
|
||||
}
|
||||
}
|
||||
|
||||
// Notify
|
||||
if ($submit || $refresh) {
|
||||
$notify_user = (int)!empty($_POST['notify']);
|
||||
|
@ -327,13 +334,6 @@ if (($delete || $mode == 'delete') && !$confirm) {
|
|||
$attach_rg_sig = (isset($_POST['attach_rg_sig'], $_POST['poster_rg']) && $_POST['poster_rg'] != -1) ? 1 : 0;
|
||||
$poster_rg_id = (isset($_POST['poster_rg']) && $_POST['poster_rg'] != -1) ? (int)$_POST['poster_rg'] : 0;
|
||||
|
||||
// Disallowed release editing with a certain status
|
||||
if (!empty($bb_cfg['tor_cannot_edit']) && $post_info['allow_reg_tracker'] && $post_data['first_post'] && !IS_AM) {
|
||||
if ($tor_status = DB()->fetch_row("SELECT tor_status FROM " . BB_BT_TORRENTS . " WHERE topic_id = $topic_id AND forum_id = $forum_id AND tor_status IN(" . implode(',', $bb_cfg['tor_cannot_edit']) . ") LIMIT 1")) {
|
||||
bb_die($lang['NOT_EDIT_TOR_STATUS'] . ': <span title="' . $lang['TOR_STATUS_NAME'][$tor_status['tor_status']] . '">' . $bb_cfg['tor_icons'][$tor_status['tor_status']] . ' ' . $lang['TOR_STATUS_NAME'][$tor_status['tor_status']] . '</span>.');
|
||||
}
|
||||
}
|
||||
|
||||
\TorrentPier\Legacy\Post::prepare_post($mode, $post_data, $error_msg, $username, $subject, $message);
|
||||
|
||||
if (!$error_msg) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue