added case differentiation to use MimeTypeByResponseHeader for remote uris and MimeTypeByExtension/FileInfo for local files