fix crash when subdir has no childs
Added support for MIME types / Content-Type headers via GIO.