dev-experiment should call method directly

This commit is contained in:
Sebastian 2022-10-31 15:16:52 -03:00
parent 9f57aa1cc5
commit e80e3f28fe
No known key found for this signature in database
GPG Key ID: BE4FF68352439FC1

View File

@ -129,10 +129,8 @@ export class DevExperimentHttpLib implements HttpRequestLibrary {
url: string, url: string,
opt?: HttpRequestOptions | undefined, opt?: HttpRequestOptions | undefined,
): Promise<HttpResponse> { ): Promise<HttpResponse> {
return this.fetch(url, { logger.info(`devexperiment httplib ${url}`);
method: "GET", return this.underlyingLib.get(url, opt);
...opt,
});
} }
postJson( postJson(
@ -140,11 +138,8 @@ export class DevExperimentHttpLib implements HttpRequestLibrary {
body: any, body: any,
opt?: HttpRequestOptions | undefined, opt?: HttpRequestOptions | undefined,
): Promise<HttpResponse> { ): Promise<HttpResponse> {
return this.fetch(url, { logger.info(`devexperiment httplib ${url}`);
method: "POST", return this.underlyingLib.postJson(url, body, opt);
body,
...opt,
});
} }
fetch( fetch(