mirror of
https://github.com/YGGverse/YGGtracker.git
synced 2026-04-01 17:45:31 +00:00
generate keywords on file parsed only
This commit is contained in:
parent
e97c4ec27f
commit
68fbafaefa
1 changed files with 28 additions and 27 deletions
|
|
@ -154,8 +154,8 @@ class TorrentService
|
||||||
{
|
{
|
||||||
$keywords = [];
|
$keywords = [];
|
||||||
|
|
||||||
$file = $this->readTorrentFileByFilepath($filepath);
|
if ($file = $this->readTorrentFileByFilepath($filepath))
|
||||||
|
{
|
||||||
foreach ($file->getFileList() as $file)
|
foreach ($file->getFileList() as $file)
|
||||||
{
|
{
|
||||||
$words = explode(
|
$words = explode(
|
||||||
|
|
@ -196,6 +196,7 @@ class TorrentService
|
||||||
|
|
||||||
$keywords = array_merge($keywords, $words);
|
$keywords = array_merge($keywords, $words);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return array_unique($keywords);
|
return array_unique($keywords);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue