aboutsummaryrefslogtreecommitdiff
path: root/internal/googlereader/handler.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/googlereader/handler.go')
-rw-r--r--internal/googlereader/handler.go15
1 files changed, 2 insertions, 13 deletions
diff --git a/internal/googlereader/handler.go b/internal/googlereader/handler.go
index 7cce675c..c3eb70af 100644
--- a/internal/googlereader/handler.go
+++ b/internal/googlereader/handler.go
@@ -24,7 +24,6 @@ import (
mff "miniflux.app/v2/internal/reader/handler"
mfs "miniflux.app/v2/internal/reader/subscription"
"miniflux.app/v2/internal/storage"
- "miniflux.app/v2/internal/urllib"
"miniflux.app/v2/internal/validator"
"github.com/gorilla/mux"
@@ -1004,18 +1003,8 @@ func (h *handler) streamItemContentsHandler(w http.ResponseWriter, r *http.Reque
}
entry.Content = mediaproxy.RewriteDocumentWithAbsoluteProxyURL(h.router, entry.Content)
- proxyOption := config.Opts.MediaProxyMode()
-
- for i := range entry.Enclosures {
- if proxyOption == "all" || proxyOption != "none" && !urllib.IsHTTPS(entry.Enclosures[i].URL) {
- for _, mediaType := range config.Opts.MediaProxyResourceTypes() {
- if strings.HasPrefix(entry.Enclosures[i].MimeType, mediaType+"/") {
- entry.Enclosures[i].URL = mediaproxy.ProxifyAbsoluteURL(h.router, entry.Enclosures[i].URL)
- break
- }
- }
- }
- }
+
+ entry.Enclosures.ProxifyEnclosureURL(h.router)
contentItems[i] = contentItem{
ID: fmt.Sprintf(EntryIDLong, entry.ID),