Skip to content

Revert "Updating the undici Major Version (#350)" #357

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: v4.x
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 19 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@azure/functions",
"version": "4.7.3",
"version": "4.7.4",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just reverting the code we do not need to update the version, can you revert to 4.7.2.

"description": "Microsoft Azure Functions NodeJS Framework",
"keywords": [
"azure",
Expand Down Expand Up @@ -43,7 +43,7 @@
"dependencies": {
"cookie": "^0.7.0",
"long": "^4.0.0",
"undici": "^7.10.0"
"undici": "^5.29.0"
},
"devDependencies": {
"@types/chai": "^4.2.22",
Expand Down
2 changes: 1 addition & 1 deletion src/constants.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the MIT License.

export const version = '4.7.3';
export const version = '4.7.4';

export const returnBindingKey = '$return';
1 change: 0 additions & 1 deletion src/http/HttpRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ export class HttpRequest implements types.HttpRequest {
}

async formData(): Promise<FormData> {
// eslint-disable-next-line deprecation/deprecation
return this.#uReq.formData();
}

Expand Down
1 change: 0 additions & 1 deletion src/http/HttpResponse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ export class HttpResponse implements types.HttpResponse {
}

async formData(): Promise<FormData> {
// eslint-disable-next-line deprecation/deprecation
return this.#uRes.formData();
}

Expand Down
3 changes: 2 additions & 1 deletion test/http/HttpRequest.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import 'mocha';
import * as chai from 'chai';
import { expect } from 'chai';
import * as chaiAsPromised from 'chai-as-promised';
import { File } from 'undici';
import { HttpRequest } from '../../src/http/HttpRequest';

chai.use(chaiAsPromised);
Expand Down Expand Up @@ -134,7 +135,7 @@ value2
const contentTypes = ['application/octet-stream', 'application/json', 'text/plain', 'invalid'];
for (const contentType of contentTypes) {
const req = createFormRequest('', contentType);
await expect(req.formData()).to.eventually.be.rejectedWith(/Content-Type was not one of /i);
await expect(req.formData()).to.eventually.be.rejectedWith(/Could not parse content as FormData/i);
}
});
});
Expand Down
Loading