Added controller.allowCORS, ability to pass data in HttpClientError
(and typo), string.truncate and tests