Changed how media types are generated, much more simple.