Fix throw e; in API