Implementing a streaming setup with Usenet

This commit is contained in:
Mukhtar Akere
2025-08-01 15:27:24 +01:00
parent afe577bf2f
commit f9861e3b54
65 changed files with 9437 additions and 924 deletions

View File

@@ -7,6 +7,7 @@ import (
"github.com/rs/zerolog"
"github.com/sirrobot01/decypharr/internal/logger"
"github.com/sirrobot01/decypharr/pkg/store"
"github.com/sirrobot01/decypharr/pkg/usenet"
"html/template"
"os"
)
@@ -61,9 +62,10 @@ type Web struct {
cookie *sessions.CookieStore
templates *template.Template
torrents *store.TorrentStorage
usenet usenet.Usenet
}
func New() *Web {
func New(usenet usenet.Usenet) *Web {
templates := template.Must(template.ParseFS(
content,
"templates/layout.html",
@@ -86,5 +88,6 @@ func New() *Web {
templates: templates,
cookie: cookieStore,
torrents: store.Get().Torrents(),
usenet: usenet,
}
}