restore metadata for audio

master
Aevann1 2022-09-03 05:39:35 +02:00
parent 28dbe0d6ab
commit a0579b40e0
2 changed files with 2 additions and 2 deletions

View File

@ -320,7 +320,7 @@ def sanitize(sanitized, edit=False, limit_pings=0, showmore=True):
sanitized = sanitized.replace(i.group(0), htmlsource) sanitized = sanitized.replace(i.group(0), htmlsource)
sanitized = video_sub_regex.sub(r'\1<video controls preload="metadata"><source src="\2"></video>', sanitized) sanitized = video_sub_regex.sub(r'\1<video controls preload="metadata"><source src="\2"></video>', sanitized)
sanitized = audio_sub_regex.sub(r'\1<audio controls preload="none" src="\2"></audio>', sanitized) sanitized = audio_sub_regex.sub(r'\1<audio controls preload="metadata" src="\2"></audio>', sanitized)
if not edit: if not edit:
for marsey in g.db.query(Marsey).filter(Marsey.name.in_(marseys_used)).all(): for marsey in g.db.query(Marsey).filter(Marsey.name.in_(marseys_used)).all():

View File

@ -774,7 +774,7 @@
{% elif p.is_audio %} {% elif p.is_audio %}
<div class="row no-gutters"> <div class="row no-gutters">
<div class="col"> <div class="col">
<audio controls preload="none" src="{{p.realurl(v)}}"></audio> <audio controls preload="metadata" src="{{p.realurl(v)}}"></audio>
</div> </div>
</div> </div>
<pre></pre> <pre></pre>