fix: passando get params mesmo no patch e puth

This commit is contained in:
Leandro Costa 2023-11-10 09:02:22 -03:00
parent f4fe302733
commit 85e0dd6e6a

View file

@ -189,20 +189,22 @@ export class LhispOauthClient<iAccessToken extends AccessToken = AccessToken> {
}); });
} }
async put<ResponseType>({ path, data, contentType = ContentType.APPLICATION_JSON }: ExecutarRequestParams) { async put<ResponseType>({ path, data, params, contentType = ContentType.APPLICATION_JSON }: ExecutarRequestParams) {
return this.executarRequest<ResponseType>({ return this.executarRequest<ResponseType>({
method: "PUT", method: "PUT",
path, path,
data, data,
params,
contentType, contentType,
}); });
} }
async patch<ResponseType>({ path, data, contentType = ContentType.APPLICATION_JSON }: ExecutarRequestParams) { async patch<ResponseType>({ path, data, params, contentType = ContentType.APPLICATION_JSON }: ExecutarRequestParams) {
return this.executarRequest<ResponseType>({ return this.executarRequest<ResponseType>({
method: "PATCH", method: "PATCH",
path, path,
data, data,
params,
contentType, contentType,
}); });
} }