From 12dc003226a0c7def95c3fe36ca0040527a02ff8 Mon Sep 17 00:00:00 2001 From: Philipp Kunz Date: Sun, 29 May 2022 20:53:16 +0200 Subject: [PATCH] fix(core): update --- ts/00_commitinfo_data.ts | 2 +- ts/index.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ts/00_commitinfo_data.ts b/ts/00_commitinfo_data.ts index ff88936..8b57081 100644 --- a/ts/00_commitinfo_data.ts +++ b/ts/00_commitinfo_data.ts @@ -3,6 +3,6 @@ */ export const commitinfo = { name: '@pushrocks/webrequest', - version: '3.0.5', + version: '3.0.6', description: 'securely request from browsers' } diff --git a/ts/index.ts b/ts/index.ts index 83125d8..38e07be 100644 --- a/ts/index.ts +++ b/ts/index.ts @@ -44,11 +44,12 @@ export class WebRequest { /** * postJson */ - public async postJson(urlArg: string, requestBody?: any, useStoreAsFallback: boolean = false) { + public async postJson(urlArg: string, requestBody?: any, useCacheArg: boolean = false) { await WebRequest.neededPolyfillsLoadedDeferred.promise; const response: Response = await this.request(urlArg, { body: plugins.smartjson.stringify(requestBody), method: 'POST', + useCache: useCacheArg }); const responseText = await response.text(); const responseResult = plugins.smartjson.parse(responseText);