mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-24 03:57:22 +08:00
text align tag + update/edit get desc + rating improve
This commit is contained in:
+7
-2
@@ -262,7 +262,12 @@ class Imdb
|
||||
|
||||
}
|
||||
|
||||
public function renderTorrentsPageAverageRating($imdbId)
|
||||
public function renderTorrentsPageAverageRating($imdbId): string
|
||||
{
|
||||
return $this->getPtGen()->buildRatingSpan([PTGen::SITE_IMDB => $this->getRating($imdbId)]);
|
||||
}
|
||||
|
||||
public function getRating($imdbId): float|string
|
||||
{
|
||||
$imdbId = parse_imdb_id($imdbId);
|
||||
$defaultRating = $rating = 'N/A';
|
||||
@@ -273,7 +278,7 @@ class Imdb
|
||||
if (!is_numeric($rating)) {
|
||||
$rating = $defaultRating;
|
||||
}
|
||||
return $this->getPtGen()->buildRatingSpan([PTGen::SITE_IMDB => $rating]);
|
||||
return $rating;
|
||||
}
|
||||
|
||||
public function getPtGen()
|
||||
|
||||
Reference in New Issue
Block a user