<commit_before>"use strict";

import { RestClientSettings } from './models/configurationSettings'
import { HttpRequest } from './models/httpRequest'
import { HttpResponse } from './models/httpResponse'

var request = require('request')

export class HttpClient {
    private _settings: RestClientSettings;

    constructor(settings: RestClientSettings) {
        this._settings = settings;
    }

    send(httpRequest: HttpRequest): Promise<HttpResponse> {
        let options = {
            url: httpRequest.url,
            headers: httpRequest.headers,
            method: httpRequest.method,
            body: httpRequest.body,
            time: true,
            timeout: this._settings.timeoutInMilliseconds,
            proxy: this._settings.proxy,
            strictSSL: this._settings.proxyStrictSSL,
            gzip: true,<commit_msg>only use proxy strict SSL when use proxy<commit_after>"use strict";

import { RestClientSettings } from './models/configurationSettings'
import { HttpRequest } from './models/httpRequest'
import { HttpResponse } from './models/httpResponse'

var request = require('request')

export class HttpClient {
    private _settings: RestClientSettings;

    constructor(settings: RestClientSettings) {
        this._settings = settings;
    }

    send(httpRequest: HttpRequest): Promise<HttpResponse> {
        let options = {
            url: httpRequest.url,
            headers: httpRequest.headers,
            method: httpRequest.method,
            body: httpRequest.body,
            time: true,
            timeout: this._settings.timeoutInMilliseconds,
            proxy: this._settings.proxy,
            strictSSL: this._settings.proxy && this._settings.proxy.length > 0 ? this._settings.proxyStrictSSL : false,
            gzip: true,
{'fraction_non_alphanumeric': 0.09523809523809523, 'fraction_numerical': 0.0005602240896358543, 'mean_word_length': 2.7442348008385746, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '64791', 'n_tokens_mistral': 447, 'n_tokens_neox': 441, 'n_words': 110}