- Fix alldebrid bug

- Minor cleanup
- speedgains
This commit is contained in:
Mukhtar Akere
2025-02-19 01:20:05 +01:00
parent 325e6c912c
commit 9a7bff04ef
9 changed files with 27 additions and 60 deletions

View File

@@ -8,6 +8,7 @@ import (
"github.com/sirrobot01/debrid-blackhole/internal/config"
"github.com/sirrobot01/debrid-blackhole/internal/logger"
"github.com/sirrobot01/debrid-blackhole/internal/request"
"github.com/sirrobot01/debrid-blackhole/internal/utils"
"github.com/sirrobot01/debrid-blackhole/pkg/debrid/torrent"
"net/http"
@@ -106,7 +107,9 @@ func flattenFiles(files []MagnetFile, parentPath string, index *int) []torrent.F
} else {
// This is a file
fileName := filepath.Base(f.Name)
if common.RegexMatch(common.SAMPLEMATCH, fileName) {
// Skip sample files
if utils.IsSampleFile(fileName) {
continue
}
if !cfg.IsAllowedFile(fileName) {