fix issue 176+177

This commit is contained in:
xiaomlove
2023-04-13 01:33:35 +08:00
parent 853c55257c
commit 9805d0fac6
3 changed files with 10 additions and 5 deletions

View File

@@ -1,6 +1,6 @@
<?php
defined('VERSION_NUMBER') || define('VERSION_NUMBER', '1.8.0');
defined('RELEASE_DATE') || define('RELEASE_DATE', '2023-04-12');
defined('RELEASE_DATE') || define('RELEASE_DATE', '2023-04-13');
defined('IN_TRACKER') || define('IN_TRACKER', false);
defined('PROJECTNAME') || define("PROJECTNAME","NexusPHP");
defined('NEXUSPHPURL') || define("NEXUSPHPURL","https://nexusphp.org");

View File

@@ -3401,6 +3401,9 @@ function torrenttable($rows, $variant = "torrent", $searchBoxId = 0) {
}
unset($row);
$enableImdb = get_setting("main.showimdbinfo") == 'yes';
$enablePtGen = get_setting('main.enable_pt_gen_systemyes') == 'yes';
$torrentSeedingLeechingStatus = $torrent->listLeechingSeedingStatus($CURUSER['id'], $torrentIdArr);
$tagRep = new \App\Repositories\TagRepository();
$torrentTagCollection = \App\Models\TorrentTag::query()->whereIn('torrent_id', $torrentIdArr)->get();
@@ -3680,8 +3683,9 @@ foreach ($rows as $row)
}
print("</td>");
echo $torrent->renderTorrentsPageAverageRating($row);
if ($enableImdb || $enablePtGen) {
echo $torrent->renderTorrentsPageAverageRating($row);
}
$act = "";
if ($CURUSER["dlicon"] != 'no' && $CURUSER["downloadpos"] != "no")
$act .= "<a href=\"download.php?id=".$id."\"><img class=\"download\" src=\"pic/trans.gif\" style='padding-bottom: 2px;' alt=\"download\" title=\"".$lang_functions['title_download_torrent']."\" /></a>" ;

View File

@@ -26,8 +26,9 @@ if ($action == "confirmuser")
if ($action == "edituser")
{
$userid = $_POST["userid"];
$userInfo = \App\Models\User::query()->findOrFail($userid, ['id', 'passkey']);
$class = intval($_POST["class"] ?? 0);
$userInfo = \App\Models\User::query()->findOrFail($userid);
// $class = intval($_POST["class"] ?? 0);
$class = $userInfo->class;
$vip_added = ($_POST["vip_added"] == 'yes' ? 'yes' : 'no');
$vip_until = !empty($_POST["vip_until"]) ? $_POST['vip_until'] : null;