From 37a04523e57282a4b639997663ebb3dbe3e27ebf Mon Sep 17 00:00:00 2001 From: Stanley Chin Date: Tue, 22 Aug 2023 09:19:42 -0400 Subject: [PATCH] lock key is just type string --- packages/schema/exported-schema.json | 9 ++++++--- packages/schema/lib/schemas/BasicOperationSchema.js | 3 ++- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/packages/schema/exported-schema.json b/packages/schema/exported-schema.json index d015112b2..323541768 100644 --- a/packages/schema/exported-schema.json +++ b/packages/schema/exported-schema.json @@ -703,7 +703,8 @@ "properties": { "key": { "description": "The key to use for locking. This should be unique to the operation.", - "$ref": "/KeySchema" + "type": "string", + "minLength": 1 }, "scope": { "description": "The level at which an app's access is restricted to. \n 'user' - Locks based on user ids. \n 'auth' - Locks based on unique auth ids\n 'account' - Locks for all users under a single account. \n You may also combine scopes.", @@ -939,7 +940,8 @@ "properties": { "key": { "description": "The key to use for locking. This should be unique to the operation.", - "$ref": "/KeySchema" + "type": "string", + "minLength": 1 }, "scope": { "description": "The level at which an app's access is restricted to. \n 'user' - Locks based on user ids. \n 'auth' - Locks based on unique auth ids\n 'account' - Locks for all users under a single account. \n You may also combine scopes.", @@ -1321,7 +1323,8 @@ "properties": { "key": { "description": "The key to use for locking. This should be unique to the operation.", - "$ref": "/KeySchema" + "type": "string", + "minLength": 1 }, "scope": { "description": "The level at which an app's access is restricted to. \n 'user' - Locks based on user ids. \n 'auth' - Locks based on unique auth ids\n 'account' - Locks for all users under a single account. \n You may also combine scopes.", diff --git a/packages/schema/lib/schemas/BasicOperationSchema.js b/packages/schema/lib/schemas/BasicOperationSchema.js index f078b79c8..3732c475d 100644 --- a/packages/schema/lib/schemas/BasicOperationSchema.js +++ b/packages/schema/lib/schemas/BasicOperationSchema.js @@ -59,7 +59,8 @@ module.exports = makeSchema( key: { description: 'The key to use for locking. This should be unique to the operation.', - $ref: KeySchema.id, + type: 'string', + minLength: 1, }, scope: { description: `The level at which an app's access is restricted to.