Skip to content

Commit 1ed9fad

Browse files
committed
Reduce createBoundary alphabet range to lowercase + numeric characters only to improve compatibility with extistent Blob implementations.
1 parent 3037a37 commit 1ed9fad

File tree

3 files changed

+121
-106
lines changed

3 files changed

+121
-106
lines changed

lib/util/createBoundary.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
1-
const alphabet
2-
= "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
1+
// TODO: Return uppercase characters back once the spec gets fixed.
2+
// Keep track on these:
3+
// 1. https://github.com/whatwg/html/issues/6251
4+
// 2. https://github.com/w3c/FileAPI/issues/43
5+
const alphabet = "abcdefghijklmnopqrstuvwxyz0123456789"
36

47
/**
58
* Generates a boundary string for FormData encoder.

package.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,23 +41,23 @@
4141
"devDependencies": {
4242
"@octetstream/eslint-config": "5.0.0",
4343
"@types/mime-types": "2.1.1",
44-
"@types/node": "16.10.2",
44+
"@types/node": "16.11.6",
4545
"@typescript-eslint/eslint-plugin": "4.33.0",
4646
"@typescript-eslint/parser": "4.33.0",
4747
"@zoltu/typescript-transformer-append-js-extension": "1.0.1",
4848
"ava": "3.15.0",
49-
"c8": "7.9.0",
49+
"c8": "7.10.0",
5050
"eslint": "7.32.0",
5151
"eslint-config-airbnb-typescript": "12.3.1",
5252
"eslint-plugin-ava": "12.0.0",
5353
"eslint-plugin-jsx-a11y": "6.4.1",
5454
"eslint-plugin-react": "7.26.1",
55-
"formdata-node": "4.3.0",
56-
"husky": "7.0.2",
57-
"lint-staged": "11.2.0",
55+
"formdata-node": "4.3.1",
56+
"husky": "7.0.4",
57+
"lint-staged": "11.2.6",
5858
"pinst": "2.1.6",
59-
"ts-node": "10.2.1",
59+
"ts-node": "10.4.0",
6060
"ttypescript": "1.5.12",
61-
"typescript": "4.4.3"
61+
"typescript": "4.4.4"
6262
}
6363
}

0 commit comments

Comments
 (0)