Commit 92b8336a authored by fred's avatar fred
Browse files

fix podcast enclosure to be full URL

parent e45ca76c
......@@ -4,6 +4,8 @@ import os
import stat
import time
from django.conf import settings
from django.views.decorators.cache import cache_control
from django.views.generic.base import TemplateView
from django.views.generic.detail import DetailView
......@@ -12,7 +14,8 @@ from django.views.generic.dates import _date_from_string
from django.core.paginator import Paginator
from django.contrib.syndication.views import Feed
from django.contrib.sites.models import Site
from django.contrib.syndication.views import Feed, add_domain
from django.utils.feedgenerator import Atom1Feed
import fiber.views
......@@ -562,7 +565,8 @@ class PodcastsFeed(Feed):
return item.episode.get_absolute_url()
def item_enclosure_url(self, item):
return item.get_format_url('mp3')
current_site = Site.objects.get(id=settings.SITE_ID)
return add_domain(current_site.domain, item.get_format_url('mp3'))
def item_enclosure_length(self, item):
sound_path = item.get_format_path('mp3')
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment