fix(core): update

This commit is contained in:
Philipp Kunz 2022-05-29 21:01:56 +02:00
parent c2c1dee427
commit 63c6dac8fa
4 changed files with 11 additions and 11 deletions

14
package-lock.json generated
View File

@ -14,7 +14,7 @@
"@pushrocks/lik": "^6.0.0",
"@pushrocks/smartdelay": "^2.0.13",
"@pushrocks/smartpromise": "^3.1.7",
"@pushrocks/webrequest": "^3.0.5"
"@pushrocks/webrequest": "^3.0.6"
},
"devDependencies": {
"@gitzone/tsbuild": "^2.1.63",
@ -1020,9 +1020,9 @@
}
},
"node_modules/@pushrocks/webrequest": {
"version": "3.0.5",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fwebrequest/-/webrequest-3.0.5.tgz",
"integrity": "sha512-5maE1sMpL9KKULf6+gozkbziyzrnyTROYbc78ly77N01Nsjd1lJcEu8ELkPjp0I6nsrDUoJYP5+FfmuvR4Y6Yw==",
"version": "3.0.6",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fwebrequest/-/webrequest-3.0.6.tgz",
"integrity": "sha512-32OopKZKqwIRYgQ1zi2TBsWRQgCDkWvpKJktlRgb95LO9HGKy+Li7DYcpqgDl7nWqKGvJ0ykZrEWAMwiXFvLfw==",
"license": "MIT",
"dependencies": {
"@pushrocks/smartdelay": "^2.0.13",
@ -7159,9 +7159,9 @@
}
},
"@pushrocks/webrequest": {
"version": "3.0.5",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fwebrequest/-/webrequest-3.0.5.tgz",
"integrity": "sha512-5maE1sMpL9KKULf6+gozkbziyzrnyTROYbc78ly77N01Nsjd1lJcEu8ELkPjp0I6nsrDUoJYP5+FfmuvR4Y6Yw==",
"version": "3.0.6",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fwebrequest/-/webrequest-3.0.6.tgz",
"integrity": "sha512-32OopKZKqwIRYgQ1zi2TBsWRQgCDkWvpKJktlRgb95LO9HGKy+Li7DYcpqgDl7nWqKGvJ0ykZrEWAMwiXFvLfw==",
"requires": {
"@pushrocks/smartdelay": "^2.0.13",
"@pushrocks/smartenv": "^5.0.2",

View File

@ -30,7 +30,7 @@
"@pushrocks/lik": "^6.0.0",
"@pushrocks/smartdelay": "^2.0.13",
"@pushrocks/smartpromise": "^3.1.7",
"@pushrocks/webrequest": "^3.0.5"
"@pushrocks/webrequest": "^3.0.6"
},
"files": [
"ts/**/*",

View File

@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@apiglobal/typedrequest',
version: '2.0.5',
version: '2.0.6',
description: 'make typed requests towards apis'
}

View File

@ -37,7 +37,7 @@ export class TypedRequest<T extends plugins.typedRequestInterfaces.ITypedRequest
/**
* fires the request
*/
public async fire(fireArg: T['request']): Promise<T['response']> {
public async fire(fireArg: T['request'], useCacheArg: boolean = false): Promise<T['response']> {
const payload: plugins.typedRequestInterfaces.ITypedRequest = {
method: this.method,
request: fireArg,
@ -50,7 +50,7 @@ export class TypedRequest<T extends plugins.typedRequestInterfaces.ITypedRequest
let responseBody: plugins.typedRequestInterfaces.ITypedRequest;
if (this.urlEndPoint) {
const response = await webrequestInstance.postJson(this.urlEndPoint, payload);
const response = await webrequestInstance.postJson(this.urlEndPoint, payload, useCacheArg);
responseBody = response;
} else {
responseBody = await this.typedTarget.post(payload);