mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-24 20:17:24 +08:00
fix medal page login check
This commit is contained in:
+2
-1
@@ -1,6 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
require "../include/bittorrent.php";
|
require "../include/bittorrent.php";
|
||||||
|
dbconn();
|
||||||
|
loggedinorreturn();
|
||||||
$query = \App\Models\Medal::query()->where('display_on_medal_page', 1);
|
$query = \App\Models\Medal::query()->where('display_on_medal_page', 1);
|
||||||
$q = htmlspecialchars($_REQUEST['q'] ?? '');
|
$q = htmlspecialchars($_REQUEST['q'] ?? '');
|
||||||
if (!empty($q)) {
|
if (!empty($q)) {
|
||||||
|
|||||||
@@ -126,7 +126,10 @@ if (!empty($_GET['sort']) && $_GET['sort'] == 'newest') {
|
|||||||
//$query = "SELECT torrents.id, torrents.category, torrents.name, torrents.small_descr, torrents.descr, torrents.info_hash, torrents.size, torrents.added, torrents.anonymous, users.username AS username, categories.id AS cat_id, categories.name AS cat_name FROM torrents LEFT JOIN categories ON category = categories.id LEFT JOIN users ON torrents.owner = users.id $where ORDER BY $sort LIMIT $limit";
|
//$query = "SELECT torrents.id, torrents.category, torrents.name, torrents.small_descr, torrents.descr, torrents.info_hash, torrents.size, torrents.added, torrents.anonymous, users.username AS username, categories.id AS cat_id, categories.name AS cat_name FROM torrents LEFT JOIN categories ON category = categories.id LEFT JOIN users ON torrents.owner = users.id $where ORDER BY $sort LIMIT $limit";
|
||||||
$query = "SELECT torrents.id, torrents.category, torrents.name, torrents.small_descr, torrents.descr, torrents.info_hash, torrents.size, torrents.added, torrents.anonymous, torrents.owner, categories.name AS category_name FROM torrents LEFT JOIN categories ON category = categories.id $where ORDER BY $sort LIMIT $limit";
|
$query = "SELECT torrents.id, torrents.category, torrents.name, torrents.small_descr, torrents.descr, torrents.info_hash, torrents.size, torrents.added, torrents.anonymous, torrents.owner, categories.name AS category_name FROM torrents LEFT JOIN categories ON category = categories.id $where ORDER BY $sort LIMIT $limit";
|
||||||
$list = \Nexus\Database\NexusDB::select($query);
|
$list = \Nexus\Database\NexusDB::select($query);
|
||||||
$list = apply_filter('torrent_list', $list, $startindex == 0 ? 0 : 1, null, $_GET['search'] ?? '');
|
if ($inclbookmarked == 0) {
|
||||||
|
$list = apply_filter('torrent_list', $list, $startindex == 0 ? 0 : 1, null, $_GET['search'] ?? '');
|
||||||
|
}
|
||||||
|
|
||||||
//dd($list);
|
//dd($list);
|
||||||
$torrentRep = new \App\Repositories\TorrentRepository();
|
$torrentRep = new \App\Repositories\TorrentRepository();
|
||||||
$url = get_protocol_prefix().$BASEURL;
|
$url = get_protocol_prefix().$BASEURL;
|
||||||
|
|||||||
Reference in New Issue
Block a user