From d81f38809bd139a1ab24093e4583cd92cf8793ab Mon Sep 17 00:00:00 2001 From: Benjamin Toby Date: Thu, 24 Oct 2024 08:08:22 +0100 Subject: [PATCH] Update types --- package-shared/types/index.d.ts | 6 ++++-- package-shared/types/index.js | 10 +++++++++- package.json | 2 +- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/package-shared/types/index.d.ts b/package-shared/types/index.d.ts index 0f1fa98..cb4019a 100644 --- a/package-shared/types/index.d.ts +++ b/package-shared/types/index.d.ts @@ -271,13 +271,15 @@ export interface GoogleIdentityPromptNotification { isSkippedMoment: () => boolean; } -export interface UserDataPayload { +export type UserDataPayload = { first_name: string; last_name: string; email: string; password: string; username: string; -} +} & { + [key: string]: any; +}; export interface GetUserFunctionReturn { success: boolean; diff --git a/package-shared/types/index.js b/package-shared/types/index.js index ea6351e..7002157 100644 --- a/package-shared/types/index.js +++ b/package-shared/types/index.js @@ -305,7 +305,11 @@ const http = require("http"); */ /** - * @typedef {object} UserDataPayload + * @typedef {UserDataPayloadBase & UserDataPayloadSupplement} UserDataPayload + */ + +/** + * @typedef {object} UserDataPayloadBase * @property {string} first_name - First Name *Required * @property {string} last_name - Last Name *Required * @property {string} email - Email *Required @@ -313,6 +317,10 @@ const http = require("http"); * @property {string} username - Username (Optional) */ +/** + * @typedef {Object.} UserDataPayloadSupplement + */ + /** * @typedef {object} GetUserFunctionReturn * @property {boolean} success - Did the function run successfully? diff --git a/package.json b/package.json index dceb35f..021cf48 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "datasquirel", - "version": "2.3.3", + "version": "2.3.4", "description": "Cloud-based SQL data management tool", "main": "index.js", "bin": {