The example has been changed due to a potential NPE if an exception is thrown when GetMarketData is called.