Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.MediaType.Suffixes returns empty array for m4v when site is deployed to GitLab #10

Open
OlafHaag opened this issue Apr 13, 2020 · 1 comment · May be fixed by #11
Open

.MediaType.Suffixes returns empty array for m4v when site is deployed to GitLab #10

OlafHaag opened this issue Apr 13, 2020 · 1 comment · May be fixed by #11

Comments

@OlafHaag
Copy link
Contributor

OlafHaag commented Apr 13, 2020

When I built my site locally, everything worked as expected. Now I pushed the site to gitlab pages and the build failed. I traced it down to .MediaType.Suffixes returning [].
The file in question is a m4v video file.

{{ if or (in .MediaType.Suffixes "mp4") (in .MediaType.Suffixes "m4v") }}

The page resource is found though. It just can't determine the extension.
I'll look for a solution.

@OlafHaag OlafHaag changed the title .MediaType.Suffixes returns empty array when site is deployed to GitLab .MediaType.Suffixes returns empty array for m4v when site is deployed to GitLab Apr 13, 2020
@OlafHaag
Copy link
Contributor Author

So it turns out this is connected to #8 . m4v is not in the built-in media types for MP4 videos.

One could override the MIME type in the theme's own configuration.
I have a working example and will create a pull request.

@OlafHaag OlafHaag linked a pull request Apr 13, 2020 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant