From c4f1db64bdfc504e5b6cb6c393438e3390edf724 Mon Sep 17 00:00:00 2001 From: SethK Date: Thu, 30 Mar 2023 13:40:26 +0530 Subject: [PATCH 1/4] Updated picker version v1.24.0 --- CHANGELOG.md | 5 +++++ package-lock.json | 2 +- package.json | 2 +- src/config.ts | 2 +- 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index dda60962..40dd006e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [3.26.0](https://github.com/filestack/filestack-js/compare/v3.25.0...v3.26.0) (2023-03-30) +### Feature + * **picker:** Added possibility to predefine the results for the imagesearch in Picker + * **picker:** Picker - Display Unsplash Search and Good Old Image Search as two tabs of one "source" + ## [3.25.0](https://github.com/filestack/filestack-js/compare/v3.24.1...v3.25.0) (2021-10-05) diff --git a/package-lock.json b/package-lock.json index 6f9dc78e..14c85065 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "filestack-js", - "version": "3.25.0", + "version": "3.26.0", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index de201d67..8973e3de 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "filestack-js", - "version": "3.25.0", + "version": "3.26.0", "description": "Official JavaScript library for Filestack", "main": "build/main/index.js", "module": "build/module/index.js", diff --git a/src/config.ts b/src/config.ts index ccd96d8b..58e237b1 100644 --- a/src/config.ts +++ b/src/config.ts @@ -18,7 +18,7 @@ /** * @private */ -const PICKER_VERSION = '1.23.0'; +const PICKER_VERSION = '1.24.0'; /** * @private From 3cdfa3257b5643f6f9e68c66c5b03b71fbcb61a9 Mon Sep 17 00:00:00 2001 From: SethK Date: Thu, 6 Apr 2023 18:18:14 +0530 Subject: [PATCH 2/4] Updated realease version and changelog --- CHANGELOG.md | 5 +++++ package-lock.json | 2 +- package.json | 2 +- src/config.ts | 2 +- 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 40dd006e..08e6f131 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [3.26.1](https://github.com/filestack/filestack-js/compare/v3.26.0...v3.26.1) (2023-04-06) + +### Fix + * **picker:** Fixed console error during file select and upload + ## [3.26.0](https://github.com/filestack/filestack-js/compare/v3.25.0...v3.26.0) (2023-03-30) ### Feature * **picker:** Added possibility to predefine the results for the imagesearch in Picker diff --git a/package-lock.json b/package-lock.json index 14c85065..19387635 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "filestack-js", - "version": "3.26.0", + "version": "3.26.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 8973e3de..a107545b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "filestack-js", - "version": "3.26.0", + "version": "3.26.1", "description": "Official JavaScript library for Filestack", "main": "build/main/index.js", "module": "build/module/index.js", diff --git a/src/config.ts b/src/config.ts index 58e237b1..1f520337 100644 --- a/src/config.ts +++ b/src/config.ts @@ -18,7 +18,7 @@ /** * @private */ -const PICKER_VERSION = '1.24.0'; +const PICKER_VERSION = '1.24.1'; /** * @private From 28096cff55a5856efbee3c903d0488f667eb2091 Mon Sep 17 00:00:00 2001 From: Zsolt Kozaroczy Date: Mon, 7 Aug 2023 10:12:08 +0200 Subject: [PATCH 3/4] Bump fast-xml-parser (#521) * build(deps): bump fast-xml-parser from 3.16.0 to 4.2.4 Bumps [fast-xml-parser](https://github.com/NaturalIntelligence/fast-xml-parser) from 3.16.0 to 4.2.4. - [Release notes](https://github.com/NaturalIntelligence/fast-xml-parser/releases) - [Changelog](https://github.com/NaturalIntelligence/fast-xml-parser/blob/master/CHANGELOG.md) - [Commits](https://github.com/NaturalIntelligence/fast-xml-parser/commits) --- updated-dependencies: - dependency-name: fast-xml-parser dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Fix code after fast-xml-parser version bump --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- package-lock.json | 14 +++++++++++--- package.json | 2 +- src/lib/request/helpers/data.ts | 9 ++++++--- 3 files changed, 18 insertions(+), 7 deletions(-) diff --git a/package-lock.json b/package-lock.json index 19387635..21957d0c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6771,9 +6771,12 @@ "dev": true }, "fast-xml-parser": { - "version": "3.16.0", - "resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-3.16.0.tgz", - "integrity": "sha512-U+bpScacfgnfNfIKlWHDu4u6rtOaCyxhblOLJ8sZPkhsjgGqdZmVPBhdOyvdMGCDt8CsAv+cssOP3NzQptNt2w==" + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-4.2.4.tgz", + "integrity": "sha512-fbfMDvgBNIdDJLdLOwacjFAPYt67tr31H9ZhWSm45CDAxvd0I6WTlSOUo7K2P/K5sA5JgMKG64PI3DMcaFdWpQ==", + "requires": { + "strnum": "^1.0.5" + } }, "fastq": { "version": "1.6.0", @@ -17006,6 +17009,11 @@ "integrity": "sha1-IrD6OkE4WzO+PzMVUbu4N/oM164=", "dev": true }, + "strnum": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/strnum/-/strnum-1.0.5.tgz", + "integrity": "sha512-J8bbNyKKXl5qYcR36TIO8W3mVGVHrmmxsd5PAItGkmyzwJvybiw2IVq5nqd0i4LSNSkB/sx9VHllbfFdr9k1JA==" + }, "stubs": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/stubs/-/stubs-3.0.0.tgz", diff --git a/package.json b/package.json index a107545b..fb9bed04 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ "abab": "^2.0.3", "debug": "^4.1.1", "eventemitter3": "^4.0.0", - "fast-xml-parser": "^3.16.0", + "fast-xml-parser": "^4.2.4", "file-type": "^10.11.0", "follow-redirects": "^1.10.0", "isutf8": "^2.1.0", diff --git a/src/lib/request/helpers/data.ts b/src/lib/request/helpers/data.ts index 6315ecd5..94dacaa6 100644 --- a/src/lib/request/helpers/data.ts +++ b/src/lib/request/helpers/data.ts @@ -18,7 +18,7 @@ import { isURLSearchParams, isObject, isStream, isFormData, isArrayBuffer, isFil import { getVersion, uniqueId } from './../../utils'; import { FsRequestOptions, FsResponse } from './../types'; import { set } from './headers'; -import * as parser from 'fast-xml-parser'; +import { XMLParser, XMLValidator } from 'fast-xml-parser'; import Debug from 'debug'; const debug = Debug('fs:request:data'); @@ -99,11 +99,14 @@ export const parseResponse = async (response: FsResponse): Promise = data = bufferToString(response.data); } - if (parser.validate(data) === true) { - response.data = parser.parse(data, { + if (XMLValidator.validate(data) === true) { + const parser = new XMLParser({ + ignoreDeclaration: true, ignoreAttributes : true, trimValues: true, }); + + response.data = parser.parse(data); } } From 41575fdf6a2bcca8c3b881627edac6d54a81cffa Mon Sep 17 00:00:00 2001 From: SethK Date: Mon, 7 Aug 2023 13:57:23 +0530 Subject: [PATCH 4/4] Updated Changelog and version --- CHANGELOG.md | 5 +++++ package-lock.json | 2 +- package.json | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 08e6f131..4ee67b88 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [3.27.0](https://github.com/filestack/filestack-js/compare/v3.26.1...v3.27.0) (2023-08-07) + +### Fix + * **fast-xml-parser:** It's a security upgrade based on ([#518](https://github.com/filestack/filestack-js/issues/518)) . Dependabot did the version bump and then fixed the tests([#521](https://github.com/filestack/filestack-js/pull/521)). + ## [3.26.1](https://github.com/filestack/filestack-js/compare/v3.26.0...v3.26.1) (2023-04-06) ### Fix diff --git a/package-lock.json b/package-lock.json index 21957d0c..001318a3 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "filestack-js", - "version": "3.26.1", + "version": "3.27.0", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index fb9bed04..6730ad18 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "filestack-js", - "version": "3.26.1", + "version": "3.27.0", "description": "Official JavaScript library for Filestack", "main": "build/main/index.js", "module": "build/module/index.js",