9
9
from django .contrib .sites .shortcuts import get_current_site
10
10
from django .urls import reverse
11
11
from django .shortcuts import get_object_or_404
12
- from django .utils .html import format_html
13
12
14
13
from .context_processors import get_available_videos
15
14
@@ -189,11 +188,10 @@ def items(self, obj):
189
188
190
189
def item_title (self , item ) -> str :
191
190
sub = re .sub (r"[\x00-\x08\x0B-\x0C\x0E-\x1F]" , "" , item .title )
192
- return "%s | %s" % ( item . owner . get_full_name (), sub )
191
+ return sub
193
192
194
193
def item_link (self , item ) -> str :
195
194
url = "" .join ([self .author_link , item .get_absolute_url ()])
196
- url += "?is_iframe=true"
197
195
return url
198
196
199
197
def item_author_name (self , item ):
@@ -212,20 +210,8 @@ def item_author_link(self, item) -> str:
212
210
)
213
211
214
212
def item_description (self , item ) -> str :
215
- thumbnail_url = "" .join ([self .prefix , item .get_thumbnail_url ().replace ("//" , "" )])
216
- title = re .sub (r"[\x00-\x08\x0B-\x0C\x0E-\x1F]" , "" , item .title )
217
- img = format_html (
218
- '<img style="max-width:100px" '
219
- 'src="%s" alt="%s" loading="lazy"/>'
220
- % (
221
- thumbnail_url ,
222
- title .replace ("{" , "" ).replace ("}" , "" ).replace ('"' , "'" ),
223
- )
224
- )
225
- description = "%s<br/>" % img
226
- sub = re .sub (r"[\x00-\x08\x0B-\x0C\x0E-\x1F]" , "" , item .description )
227
213
# use re sub to remove Control characters are not supported in XML 1.0
228
- description += sub # item.description
214
+ description = re . sub ( r"[\x00-\x08\x0B-\x0C\x0E-\x1F]" , "" , item . description ) # item.description
229
215
description += "<br/> %s: %s" % (_ ("Duration" ), item .duration_in_time )
230
216
return description
231
217
0 commit comments