Favour items in both accept header and media types

Currently, if media_types is provided it always overrides the accept header. With this patch, if a content type is provided in both the accept header and the media_types it will be favoured over other things in the media_types.