Fix a regression in REST JSON rendering and fix an unhandled error handling issue (OMS-548)