From b07f0617a38cb16d7e0022af8363bb1f3e8d79a8 Mon Sep 17 00:00:00 2001 From: Juiced66 <80784430+Juiced66@users.noreply.github.com> Date: Thu, 19 Dec 2024 09:06:59 +0100 Subject: [PATCH 1/3] fix: add default options to security:checkRights (#757) --- src/controllers/Security.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controllers/Security.ts b/src/controllers/Security.ts index 6a832337..b16aae98 100644 --- a/src/controllers/Security.ts +++ b/src/controllers/Security.ts @@ -52,7 +52,7 @@ export class SecurityController extends BaseController { checkRights( kuid, requestPayload, - options: ArgsSecurityControllerCheckRights + options: ArgsSecurityControllerCheckRights = {} ) { const request = { action: "checkRights", From 84e7a1b403a7da0b93f73a8d30e3c94e40b83993 Mon Sep 17 00:00:00 2001 From: cyrng <165774024+cyrng@users.noreply.github.com> Date: Wed, 12 Feb 2025 15:47:59 +0100 Subject: [PATCH 2/3] feat: create an interface to export and use in KDM (#758) --- src/controllers/Document.ts | 48 +++++++++++++++++++------------------ 1 file changed, 25 insertions(+), 23 deletions(-) diff --git a/src/controllers/Document.ts b/src/controllers/Document.ts index 92be9930..cb8dbf36 100644 --- a/src/controllers/Document.ts +++ b/src/controllers/Document.ts @@ -716,29 +716,7 @@ export class DocumentController extends BaseController { query: JSONObject, changes: Partial, options: ArgsDocumentControllerUpdateByQuery = {} - ): Promise<{ - /** - * Array of successfully updated documents - */ - successes: KDocument[]; - /** - * Array of failed creation - */ - errors: Array<{ - /** - * Document that cause the error - */ - document: KDocument; - /** - * HTTP error status - */ - status: number; - /** - * Human readable reason - */ - reason: string; - }>; - }> { + ): Promise> { const request = { action: "updateByQuery", body: { changes, query }, @@ -940,3 +918,27 @@ export interface ArgsDocumentControllerUpsert } export type ArgsDocumentControllerValidate = ArgsDefault; + +export interface UpdateByQueryResponse { + /** + * Array of successfully updated documents + */ + successes: KDocument[]; + /** + * Array of failed creation + */ + errors: Array<{ + /** + * Document that cause the error + */ + document: KDocument; + /** + * HTTP error status + */ + status: number; + /** + * Human readable reason + */ + reason: string; + }>; +} From 81c0b94cd056b0f6c546a10ba56160d57a7c0e41 Mon Sep 17 00:00:00 2001 From: semantic-release-bot Date: Wed, 12 Feb 2025 14:59:28 +0000 Subject: [PATCH 3/3] chore(release): 7.15.0-beta.1 [skip ci] # [7.15.0-beta.1](https://github.com/kuzzleio/sdk-javascript/compare/v7.14.0...v7.15.0-beta.1) (2025-02-12) ### Bug Fixes * add default options to security:checkRights ([#757](https://github.com/kuzzleio/sdk-javascript/issues/757)) ([b07f061](https://github.com/kuzzleio/sdk-javascript/commit/b07f0617a38cb16d7e0022af8363bb1f3e8d79a8)) ### Features * create an interface to export and use in KDM ([#758](https://github.com/kuzzleio/sdk-javascript/issues/758)) ([84e7a1b](https://github.com/kuzzleio/sdk-javascript/commit/84e7a1b403a7da0b93f73a8d30e3c94e40b83993)) --- CHANGELOG.md | 12 ++++++++++++ package-lock.json | 4 ++-- package.json | 2 +- 3 files changed, 15 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7e3b88e2..df1611e4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,15 @@ +# [7.15.0-beta.1](https://github.com/kuzzleio/sdk-javascript/compare/v7.14.0...v7.15.0-beta.1) (2025-02-12) + + +### Bug Fixes + +* add default options to security:checkRights ([#757](https://github.com/kuzzleio/sdk-javascript/issues/757)) ([b07f061](https://github.com/kuzzleio/sdk-javascript/commit/b07f0617a38cb16d7e0022af8363bb1f3e8d79a8)) + + +### Features + +* create an interface to export and use in KDM ([#758](https://github.com/kuzzleio/sdk-javascript/issues/758)) ([84e7a1b](https://github.com/kuzzleio/sdk-javascript/commit/84e7a1b403a7da0b93f73a8d30e3c94e40b83993)) + # [7.14.0](https://github.com/kuzzleio/sdk-javascript/compare/v7.13.0...v7.14.0) (2024-11-05) diff --git a/package-lock.json b/package-lock.json index d0489dfe..489a52e7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "kuzzle-sdk", - "version": "7.14.0", + "version": "7.15.0-beta.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "kuzzle-sdk", - "version": "7.14.0", + "version": "7.15.0-beta.1", "license": "Apache-2.0", "dependencies": { "min-req-promise": "^1.0.1", diff --git a/package.json b/package.json index ec59a482..fa0bdbc5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "kuzzle-sdk", - "version": "7.14.0", + "version": "7.15.0-beta.1", "description": "Official Javascript SDK for Kuzzle", "author": "The Kuzzle Team ", "repository": {