mirror of
https://github.com/YGGverse/btracker.git
synced 2026-03-31 09:05:30 +00:00
remove extra filter as already filtered by self::files
This commit is contained in:
parent
d5821c3ba6
commit
a5133b006b
1 changed files with 1 additions and 10 deletions
|
|
@ -70,16 +70,7 @@ impl Public {
|
|||
let t = f.len();
|
||||
let l = limit.unwrap_or(t);
|
||||
let mut b = Vec::with_capacity(l);
|
||||
for file in f
|
||||
.into_iter()
|
||||
.skip(start.unwrap_or_default())
|
||||
.take(l)
|
||||
.filter(|f| {
|
||||
f.path()
|
||||
.extension()
|
||||
.is_some_and(|e| !e.is_empty() && e.to_string_lossy() == EXTENSION)
|
||||
})
|
||||
{
|
||||
for file in f.into_iter().skip(start.unwrap_or_default()).take(l) {
|
||||
b.push(Torrent {
|
||||
bytes: fs::read(file.path())?,
|
||||
time: file.metadata()?.modified()?.into(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue