mirror of
https://github.com/mickael-kerjean/filestash.git
synced 2026-10-20 00:15:40 +00:00
we used to have tons of legacy stuff coming from the very first react client that got migrated over to the vanilla js one so we could finally remove the dirty tricks that made the first react client not great
11 lines
356 B
JavaScript
11 lines
356 B
JavaScript
export default function (mime, url, transcoderEnabled = {{ .enabled }}) {
|
|
if (!transcoderEnabled) return [[mime, url]];
|
|
{{- range $item := splitList "," .blacklist }}
|
|
if (mime == "{{ $item | trim }}") return [[mime, url]];
|
|
{{- end }}
|
|
return [
|
|
[ "application/x-mpegURL", url + "&transcode=hls" ],
|
|
[ mime, url ],
|
|
];
|
|
}
|