[SOLVED] Getting the file ending of an asset

Hey there,

I have a NodeType with a property of type Asset. The user is able to upload a video with this NodeType.
Is there a possibility to get the file ending of the uploaded video directly inside the template?

  <source src="{f:uri.resource(resource: media.resource)}" type="video/{media.whateverStandsForFileEnding}">

Thanks for the help!

You should be able to use mediaType(media.resource.mediaType) - it holds the full IANA media type

Thanks @sorenmalling, it works great!