From b616ed12dfd3eeb0d48bf040cf16615d78888850 Mon Sep 17 00:00:00 2001 From: kilo Date: Tue, 5 Sep 2017 09:37:09 +0200 Subject: [PATCH] Forgot to create variables --- controllers/torrent/download.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/controllers/torrent/download.go b/controllers/torrent/download.go index a47412397..786b9d00c 100644 --- a/controllers/torrent/download.go +++ b/controllers/torrent/download.go @@ -19,6 +19,7 @@ func DownloadTorrent(c *gin.Context) { if hash == "" && len(config.Get().Torrents.FileStorage) == 0 { //File not found, send 404 + variables := templates.Commonvariables(c) templates.Render(c, "errors/torrent_file_missing.jet.html", variables) return } @@ -27,6 +28,7 @@ func DownloadTorrent(c *gin.Context) { Openfile, err := os.Open(fmt.Sprintf("%s%c%s.torrent", config.Get().Torrents.FileStorage, os.PathSeparator, hash)) if err != nil { //File not found, send 404 + variables := templates.Commonvariables(c) templates.Render(c, "errors/torrent_file_missing.jet.html", variables) return } @@ -40,6 +42,7 @@ func DownloadTorrent(c *gin.Context) { if err != nil { //File not found, send 404 + variables := templates.Commonvariables(c) templates.Render(c, "errors/torrent_file_missing.jet.html", variables) return }