mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-24 03:57:22 +08:00
fix torrent list ptgen array render
This commit is contained in:
@@ -74,7 +74,11 @@ class Torrent
|
|||||||
if (is_null($ptGen)) {
|
if (is_null($ptGen)) {
|
||||||
$ptGen = new PTGen();
|
$ptGen = new PTGen();
|
||||||
}
|
}
|
||||||
$ptGenInfo = json_decode($torrentInfo['pt_gen'], true);
|
$ptGenInfo = $torrentInfo['pt_gen'];
|
||||||
|
if (!is_array($torrentInfo['pt_gen'])) {
|
||||||
|
$ptGenInfo = json_decode($ptGenInfo, true);
|
||||||
|
}
|
||||||
|
|
||||||
$log = "torrent: " . $torrentInfo['id'];
|
$log = "torrent: " . $torrentInfo['id'];
|
||||||
$siteIdAndRating = $ptGen->listRatings($ptGenInfo ?? [], $torrentInfo['url']);
|
$siteIdAndRating = $ptGen->listRatings($ptGenInfo ?? [], $torrentInfo['url']);
|
||||||
$log .= "siteIdAndRating: " . json_encode($siteIdAndRating);
|
$log .= "siteIdAndRating: " . json_encode($siteIdAndRating);
|
||||||
|
|||||||
Reference in New Issue
Block a user