Restful: Catch exception when json not returned.