Refactor extracting content types from Accept HTTP header