Compare commits

...

2 Commits

Author SHA1 Message Date
17eaea4124 3.0.4 2022-07-29 01:37:47 +02:00
d3d8f6ff57 fix(core): update 2022-07-29 01:37:47 +02:00
4 changed files with 12 additions and 4 deletions

4
package-lock.json generated
View File

@ -1,12 +1,12 @@
{ {
"name": "@pushrocks/smartproxy", "name": "@pushrocks/smartproxy",
"version": "3.0.3", "version": "3.0.4",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "@pushrocks/smartproxy", "name": "@pushrocks/smartproxy",
"version": "3.0.3", "version": "3.0.4",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@pushrocks/lik": "^6.0.0", "@pushrocks/lik": "^6.0.0",

View File

@ -1,6 +1,6 @@
{ {
"name": "@pushrocks/smartproxy", "name": "@pushrocks/smartproxy",
"version": "3.0.3", "version": "3.0.4",
"private": false, "private": false,
"description": "a proxy for handling high workloads of proxying", "description": "a proxy for handling high workloads of proxying",
"main": "dist_ts/index.js", "main": "dist_ts/index.js",

View File

@ -3,6 +3,6 @@
*/ */
export const commitinfo = { export const commitinfo = {
name: '@pushrocks/smartproxy', name: '@pushrocks/smartproxy',
version: '3.0.3', version: '3.0.4',
description: 'a proxy for handling high workloads of proxying' description: 'a proxy for handling high workloads of proxying'
} }

View File

@ -310,6 +310,14 @@ JNj2Dr5H0XoLFFnvuvzcRbhlJ9J67JzR+7g=
this.httpsServer.listen(this.port); */ this.httpsServer.listen(this.port); */
} }
public async addDefaultHeaders(headersArg: {
[key: string]: string;
}) {
for (const headerKey of Object.keys(headersArg)) {
this.defaultHeaders[headerKey] = headersArg[headerKey];
}
}
public async stop() { public async stop() {
const done = plugins.smartpromise.defer(); const done = plugins.smartpromise.defer();
this.httpsServer.close(() => { this.httpsServer.close(() => {