From ee616b1382012b6f835ce15d4bb0113376a4d087 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Fri, 24 Nov 2023 09:59:45 +0100 Subject: [PATCH] use unique --- .../move/data-type-move.server.data-source.ts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/data-type/repository/move/data-type-move.server.data-source.ts b/src/Umbraco.Web.UI.Client/src/packages/core/data-type/repository/move/data-type-move.server.data-source.ts index 6f02196613..852385bd5f 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/core/data-type/repository/move/data-type-move.server.data-source.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/core/data-type/repository/move/data-type-move.server.data-source.ts @@ -21,24 +21,24 @@ export class UmbDataTypeMoveServerDataSource implements UmbMoveDataSource { } /** - * Move an item for the given id to the target id - * @param {string} id - * @param {(string | null)} targetId + * Move an item for the given id to the target unique + * @param {string} unique + * @param {(string | null)} targetUnique * @return {*} * @memberof UmbDataTypeMoveServerDataSource */ - async move(id: string, targetId: string | null) { - if (!id) throw new Error('Id is missing'); - if (targetId === undefined) throw new Error('Target Id is missing'); + async move(unique: string, targetUnique: string | null) { + if (!unique) throw new Error('Unique is missing'); + if (targetUnique === undefined) throw new Error('Target unique is missing'); return tryExecuteAndNotify( this.#host, DataTypeResource.postDataTypeByIdMove({ - id, + id: unique, requestBody: { - targetId, + targetId: targetUnique, }, - }) + }), ); } }