Simplified the JMedium -> Medium conversion