From 4defbd75b822a3e9988d0b2f2d7684b81ce1fab5 Mon Sep 17 00:00:00 2001 From: gentlementlegen Date: Mon, 8 Apr 2024 23:19:23 +0900 Subject: [PATCH] chore: changed username to be user id --- package.json | 2 +- src/adapters/supabase/helpers/user.ts | 11 ------- src/adapters/supabase/helpers/wallet.ts | 35 ++++------------------- src/handlers/encode-decode.ts | 4 +-- src/handlers/generate-erc20-permit.ts | 18 ++++++------ src/handlers/generate-erc721-permit.ts | 34 +++++++++++++--------- src/handlers/generate-payout-permit.ts | 6 ++-- src/index.ts | 1 + src/types/index.ts | 1 + src/types/permits.ts | 5 +++- src/types/plugin-input.ts | 2 +- src/utils/helpers.ts | 20 ------------- tests/constants.ts | 2 +- tests/generate-erc721-permit.test.ts | 21 +++++++------- tests/generate-payout-permit.test.ts | 4 +-- yarn.lock | 38 ++++++++++++------------- 16 files changed, 78 insertions(+), 126 deletions(-) create mode 100644 src/types/index.ts diff --git a/package.json b/package.json index e7c8b6f..b8f333c 100644 --- a/package.json +++ b/package.json @@ -32,7 +32,7 @@ "@octokit/webhooks": "^13.1.0", "@octokit/webhooks-types": "^7.3.1", "@sinclair/typebox": "^0.32.5", - "@supabase/supabase-js": "^2.39.7", + "@supabase/supabase-js": "2.42.0", "@uniswap/permit2-sdk": "^1.2.0", "blake2b": "^2.1.4", "decimal.js": "^10.4.3", diff --git a/src/adapters/supabase/helpers/user.ts b/src/adapters/supabase/helpers/user.ts index 58ce803..54bf03f 100644 --- a/src/adapters/supabase/helpers/user.ts +++ b/src/adapters/supabase/helpers/user.ts @@ -19,17 +19,6 @@ export class User extends Super { return data; } - async getUserIdByUsername(username: string) { - const { data, error } = await this.supabase.from("users").select("id").eq("username", username).single(); - if (error) { - console.error(FAILED_TO_GET_USER, { username, error }); - throw error; - } - - console.log(SUCCESSFULLY_FETCHED_USER, { username, userId: data?.id }); - return data?.id; - } - async getUserIdByWallet(wallet: string) { const { data, error } = await this.supabase.from("wallets").select("id").eq("address", wallet).single(); if (error) { diff --git a/src/adapters/supabase/helpers/wallet.ts b/src/adapters/supabase/helpers/wallet.ts index a915e9a..dbb03f3 100644 --- a/src/adapters/supabase/helpers/wallet.ts +++ b/src/adapters/supabase/helpers/wallet.ts @@ -9,49 +9,24 @@ export class Wallet extends Super { } async getWalletByUserId(userId: number) { - const { data, error } = await this.supabase.from("wallets").select("address").eq("user_id", userId).single(); + const { data, error } = await this.supabase.from("users").select("wallets(*)").eq("id", userId).single(); if (error) { console.error("Failed to get wallet", { userId, error }); throw error; } - console.info("Successfully fetched wallet", { userId, address: data.address }); - return data.address; - } - - async getWalletByUsername(username: string) { - const { data, error } = await this.supabase.from("users").select("id").eq("username", username).single(); - if (error) { - console.error("Failed to get user", { username, error }); - throw error; - } - - const userId = data?.id; - - if (!userId) { - console.error("Failed to get user", { username }); - throw new Error("User not found"); - } - - const { data: walletData, error: walletError } = await this.supabase.from("wallets").select("address").eq("user_id", userId).single(); - - if (walletError) { - console.error("Failed to get wallet", { userId, error }); - throw walletError; - } - - console.info("Successfully fetched wallet", { userId, address: walletData?.address }); - - return walletData?.address as `0x${string}` | undefined; + console.info("Successfully fetched wallet", { userId, address: data.wallets?.address }); + return data.wallets?.address; } async upsertWallet(userId: number, address: string) { + // TODO: fix to link to user const { error } = await this.supabase.from("wallets").upsert([{ user_id: userId.toString(), address }]); if (error) { console.error("Failed to upsert wallet", { userId, address, error }); throw error; } - console.info("Successfully upserted wallet", { userId, address }); + console.info("Successfully upsert wallet", { userId, address }); } } diff --git a/src/handlers/encode-decode.ts b/src/handlers/encode-decode.ts index 5b6c129..423077f 100644 --- a/src/handlers/encode-decode.ts +++ b/src/handlers/encode-decode.ts @@ -1,4 +1,4 @@ -import { Permit } from "../types/permits"; +import { Permit, TokenType } from "../types"; /** * Returns a base64 encoded string containing all the permit data @@ -7,7 +7,7 @@ export function encodePermits(permits: Permit[]) { return Buffer.from( JSON.stringify( permits.map((permit) => { - if (permit.tokenType === "ERC20") { + if (permit.tokenType === TokenType.ERC20) { return { type: "erc20-permit", permit: { diff --git a/src/handlers/generate-erc20-permit.ts b/src/handlers/generate-erc20-permit.ts index 8479f83..adf9371 100644 --- a/src/handlers/generate-erc20-permit.ts +++ b/src/handlers/generate-erc20-permit.ts @@ -1,34 +1,32 @@ import { PERMIT2_ADDRESS, PermitTransferFrom, SignatureTransfer } from "@uniswap/permit2-sdk"; import { ethers, keccak256, MaxInt256, parseUnits, toUtf8Bytes } from "ethers"; import { Context, Logger } from "../types/context"; -import { Permit } from "../types/permits"; +import { Permit, TokenType } from "../types"; import { decryptKeys } from "../utils/keys"; import { getPayoutConfigByNetworkId } from "../utils/payoutConfigByNetworkId"; export async function generateErc20PermitSignature( - username: string, + userId: number, amount: number, evmNetworkId: number, evmPrivateEncrypted: string, - userId: number, walletAddress: string, issueId: number, logger: Logger ): Promise; -export async function generateErc20PermitSignature(username: string, amount: number, context: Context): Promise; +export async function generateErc20PermitSignature(userId: number, amount: number, context: Context): Promise; export async function generateErc20PermitSignature( - username: string, + userId: number, amount: number, contextOrNetworkId: Context | number, evmPrivateEncrypted?: string, - userId?: number, walletAddress?: string, issueId?: number, logger?: Logger ): Promise { let _logger: Logger; let _userId: number; - let _walletAddress: string | null; + let _walletAddress: string | null | undefined; let _issueId: number; let _evmNetworkId: number; let _evmPrivateEncrypted: string; @@ -44,8 +42,8 @@ export async function generateErc20PermitSignature( const config = contextOrNetworkId.config; _logger = contextOrNetworkId.logger; const { evmNetworkId, evmPrivateEncrypted } = config; - const { user, wallet } = contextOrNetworkId.adapters.supabase; - _userId = await user.getUserIdByUsername(username); + const { wallet } = contextOrNetworkId.adapters.supabase; + _userId = userId; _walletAddress = await wallet.getWalletByUserId(_userId); _evmNetworkId = evmNetworkId; _evmPrivateEncrypted = evmPrivateEncrypted; @@ -120,7 +118,7 @@ export async function generateErc20PermitSignature( }); const erc20Permit: Permit = { - tokenType: "ERC20", + tokenType: TokenType.ERC20, tokenAddress: permitTransferFromData.permitted.token, beneficiary: permitTransferFromData.spender, nonce: permitTransferFromData.nonce.toString(), diff --git a/src/handlers/generate-erc721-permit.ts b/src/handlers/generate-erc721-permit.ts index 0eaf063..d4059eb 100644 --- a/src/handlers/generate-erc721-permit.ts +++ b/src/handlers/generate-erc721-permit.ts @@ -1,10 +1,9 @@ -import { getPayoutConfigByNetworkId } from "../utils/payoutConfigByNetworkId"; -import { ethers } from "ethers"; import { MaxUint256 } from "@uniswap/permit2-sdk"; -import { keccak256, toUtf8Bytes } from "ethers"; -import { Permit } from "../types/permits"; +import { ethers, keccak256, toUtf8Bytes } from "ethers"; import { Context, Logger } from "../types/context"; +import { Permit, TokenType } from "../types"; import { isIssueEvent } from "../types/typeguards"; +import { getPayoutConfigByNetworkId } from "../utils/payoutConfigByNetworkId"; interface Erc721PermitSignatureData { beneficiary: string; @@ -31,18 +30,18 @@ export interface PermitPayload { evmNetworkId: number; nftMinterPrivateKey: string; nftContractAddress: string; - userId: string; walletAddress: string; logger: Logger; issueId: string; organizationName: string; repositoryName: string; + userName: string; } -export async function generateErc721PermitSignature(username: string, contributionType: string, permitPayload: PermitPayload): Promise; -export async function generateErc721PermitSignature(username: string, contributionType: string, context: Context): Promise; +export async function generateErc721PermitSignature(userId: number, contributionType: string, permitPayload: PermitPayload): Promise; +export async function generateErc721PermitSignature(userId: number, contributionType: string, context: Context): Promise; export async function generateErc721PermitSignature( - username: string, + userId: number, contributionType: string, contextOrPermitPayload: Context | PermitPayload ): Promise { @@ -50,11 +49,12 @@ export async function generateErc721PermitSignature( let _nftContractAddress: string; let _evmNetworkId: number; let _nftMinterPrivateKey: string; - let _userId: string; + let _userId: number; let _walletAddress: string; let _issueId: string; let _organizationName: string; let _repositoryName: string; + let _username: string; if ("evmNetworkId" in contextOrPermitPayload) { _logger = contextOrPermitPayload.logger; @@ -62,10 +62,11 @@ export async function generateErc721PermitSignature( _nftMinterPrivateKey = contextOrPermitPayload.nftMinterPrivateKey; _evmNetworkId = contextOrPermitPayload.evmNetworkId; _walletAddress = contextOrPermitPayload.walletAddress; - _userId = contextOrPermitPayload.userId; + _userId = userId; _issueId = contextOrPermitPayload.issueId; _organizationName = contextOrPermitPayload.organizationName; _repositoryName = contextOrPermitPayload.repositoryName; + _username = contextOrPermitPayload.userName; } else { const { NFT_MINTER_PRIVATE_KEY, NFT_CONTRACT_ADDRESS } = contextOrPermitPayload.env; const { evmNetworkId } = contextOrPermitPayload.config; @@ -74,13 +75,13 @@ export async function generateErc721PermitSignature( _nftContractAddress = NFT_CONTRACT_ADDRESS; _evmNetworkId = evmNetworkId; _nftMinterPrivateKey = NFT_MINTER_PRIVATE_KEY; - const walletAddress = await adapters.supabase.wallet.getWalletByUsername(username); + _userId = userId; + const walletAddress = await adapters.supabase.wallet.getWalletByUserId(_userId); if (!walletAddress) { _logger.error("No wallet found for user"); throw new Error("No wallet found for user"); } _walletAddress = walletAddress; - _userId = await adapters.supabase.user.getUserIdByWallet(_walletAddress); if (isIssueEvent(contextOrPermitPayload)) { _issueId = contextOrPermitPayload.payload.issue.id.toString(); } else { @@ -88,6 +89,11 @@ export async function generateErc721PermitSignature( } _organizationName = contextOrPermitPayload.payload.repository.owner.login; _repositoryName = contextOrPermitPayload.payload.repository.name; + const { data: userData } = await contextOrPermitPayload.octokit.request("GET /user/:id", { id: _userId }); + if (!userData) { + throw new Error(`GitHub user was not found for id ${_userId}`); + } + _username = userData.login; } const { rpc } = getPayoutConfigByNetworkId(_evmNetworkId); @@ -123,7 +129,7 @@ export async function generateErc721PermitSignature( GITHUB_ORGANIZATION_NAME: _organizationName, GITHUB_REPOSITORY_NAME: _repositoryName, GITHUB_ISSUE_ID: _issueId, - GITHUB_USERNAME: username, + GITHUB_USERNAME: _username, GITHUB_CONTRIBUTION_TYPE: contributionType, }; @@ -149,7 +155,7 @@ export async function generateErc721PermitSignature( }); const erc721Permit: Permit = { - tokenType: "ERC721", + tokenType: TokenType.ERC721, tokenAddress: _nftContractAddress, beneficiary: _walletAddress, amount: "1", diff --git a/src/handlers/generate-payout-permit.ts b/src/handlers/generate-payout-permit.ts index 4b94439..c42c5a8 100644 --- a/src/handlers/generate-payout-permit.ts +++ b/src/handlers/generate-payout-permit.ts @@ -14,15 +14,15 @@ export async function generatePayoutPermit(context: Context, permitRequests: Per const permits: Permit[] = []; for (const permitRequest of permitRequests) { - const { type, amount, username, contributionType } = permitRequest; + const { type, amount, userId, contributionType } = permitRequest; let permit: Permit; switch (type) { case "ERC20": - permit = await generateErc20PermitSignature(username, amount, context); + permit = await generateErc20PermitSignature(userId, amount, context); break; case "ERC721": - permit = await generateErc721PermitSignature(username, contributionType, context); + permit = await generateErc721PermitSignature(userId, contributionType, context); break; default: context.logger.error(`Invalid permit type: ${type}`); diff --git a/src/index.ts b/src/index.ts index 8226758..69c6f60 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,3 +1,4 @@ export * from "./handlers"; export * from "./adapters"; export * from "./generate-permits-from-context"; +export * from "./types"; diff --git a/src/types/index.ts b/src/types/index.ts new file mode 100644 index 0000000..96fa5c7 --- /dev/null +++ b/src/types/index.ts @@ -0,0 +1 @@ +export * from "./permits"; diff --git a/src/types/permits.ts b/src/types/permits.ts index f7bc151..5c4807b 100644 --- a/src/types/permits.ts +++ b/src/types/permits.ts @@ -1,4 +1,7 @@ -type TokenType = "ERC20" | "ERC721"; +export enum TokenType { + ERC20 = "ERC20", + ERC721 = "ERC721", +} export interface Permit { tokenType: TokenType; diff --git a/src/types/plugin-input.ts b/src/types/plugin-input.ts index 8668f98..5fa1219 100644 --- a/src/types/plugin-input.ts +++ b/src/types/plugin-input.ts @@ -13,7 +13,7 @@ export interface PluginInputs { export const permitRequestSchema = T.Object({ type: T.Union([T.Literal("ERC20"), T.Literal("ERC721")]), - username: T.String(), + userId: T.Number(), amount: T.Number(), contributionType: T.String(), }); diff --git a/src/utils/helpers.ts b/src/utils/helpers.ts index 4d3788f..7efabe2 100644 --- a/src/utils/helpers.ts +++ b/src/utils/helpers.ts @@ -1,26 +1,6 @@ import Decimal from "decimal.js"; import { Context } from "../types/context"; -export async function getWalletRecord(context: Context, senderID?: number, username?: string) { - const { wallet } = context.adapters.supabase; - let walletRecord = null; - - if (senderID) { - walletRecord = await wallet.getWalletByUserId(senderID); - } - - if (username) { - walletRecord = await wallet.getWalletByUsername(username); - } - - if (!walletRecord) { - context.logger.error("No wallet found for user"); - return null; - } - - return walletRecord; -} - export async function handleNoWalletFound(context: Context, issueNumber: number, userLogin: string) { const { logger, octokit } = context; const repository = context.payload.repository; diff --git a/tests/constants.ts b/tests/constants.ts index f67ea4d..8bcd0a5 100644 --- a/tests/constants.ts +++ b/tests/constants.ts @@ -1,7 +1,7 @@ import { Context } from "../src/types/context"; export const NFT_CONTRACT_ADDRESS = "0x0000000000000000000000000000000000000003"; -export const SPENDER = "0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d"; +export const SPENDER = 123; export const WALLET_ADDRESS = "0xefC0e701A824943b469a694aC564Aa1efF7Ab7dd"; diff --git a/tests/generate-erc721-permit.test.ts b/tests/generate-erc721-permit.test.ts index a0e6cc6..11cf87d 100644 --- a/tests/generate-erc721-permit.test.ts +++ b/tests/generate-erc721-permit.test.ts @@ -1,6 +1,6 @@ import { MaxUint256 } from "@uniswap/permit2-sdk"; import { keccak256, toUtf8Bytes } from "ethers"; -import { generateErc721PermitSignature } from "../src/handlers/generate-erc721-permit"; +import { generateErc721PermitSignature } from "../src"; import { Context } from "../src/types/context"; import { Env } from "../src/types/env"; import { cypherText, mockContext, NFT_CONTRACT_ADDRESS, SPENDER } from "./constants"; @@ -35,7 +35,6 @@ describe("generateErc721PermitSignature", () => { // nft specific inputs contribution_type: "contribution", - username: "tester", issueID: 123, }, } as unknown as Context; @@ -58,7 +57,7 @@ describe("generateErc721PermitSignature", () => { }), }; }); - (context.adapters.supabase.wallet.getWalletByUsername as jest.Mock).mockReturnValue(SPENDER); + (context.adapters.supabase.wallet.getWalletByUserId as jest.Mock).mockReturnValue(SPENDER); (context.adapters.supabase.user.getUserIdByWallet as jest.Mock).mockReturnValue(userId); }); @@ -69,9 +68,9 @@ describe("generateErc721PermitSignature", () => { it("should generate ERC721 permit signature", async () => { const issueId = 123; const contributionType = "contribution"; - const username = "tester"; + const userId = 123; - const result = await generateErc721PermitSignature(username, contributionType, context); + const result = await generateErc721PermitSignature(userId, contributionType, context); const organizationName = "test"; const repositoryName = "test"; @@ -87,7 +86,7 @@ describe("generateErc721PermitSignature", () => { expect(result.beneficiary).toBe(SPENDER); expect(result.deadline).toBe(MaxUint256.toString()); expect(result.nonce).toBe(BigInt(keccak256(toUtf8Bytes(`${userId}-${issueId}`))).toString()); - expect(result.erc721Request?.values).toEqual([organizationName, repositoryName, issueNumber, username, contributionType]); + expect(result.erc721Request?.values).toEqual([organizationName, repositoryName, issueNumber, userId, contributionType]); expect(result.networkId).toBe(context.config.evmNetworkId); const keysHashed = keys.map((key) => keccak256(toUtf8Bytes(key))); expect(result.erc721Request?.keys).toEqual(keysHashed); @@ -98,30 +97,30 @@ describe("generateErc721PermitSignature", () => { it("should throw an error if RPC is not defined", async () => { context.config.evmNetworkId = 123; - await expect(generateErc721PermitSignature("tester", "contribution", context)).rejects.toThrow("No config setup for" + " evmNetworkId: 123"); + await expect(generateErc721PermitSignature(123, "contribution", context)).rejects.toThrow("No config setup for" + " evmNetworkId: 123"); }); it("should throw an error if NFT minter private key is not defined", async () => { delete process.env.NFT_MINTER_PRIVATE_KEY; - await expect(generateErc721PermitSignature("tester", "contribution", context)).rejects.toThrow("Failed to instantiate" + " wallet"); + await expect(generateErc721PermitSignature(123, "contribution", context)).rejects.toThrow("Failed to instantiate" + " wallet"); expect(context.logger.error).toHaveBeenCalled(); }); it("should throw an error if NFT contract address is not defined", async () => { delete process.env.NFT_CONTRACT_ADDRESS; - await expect(generateErc721PermitSignature("tester", "contribution", context)).rejects.toThrow("NFT contract address is" + " not defined"); + await expect(generateErc721PermitSignature(123, "contribution", context)).rejects.toThrow("NFT contract address is" + " not defined"); expect(context.logger.error).toHaveBeenCalled(); }); it("should throw an error if no wallet found for user", async () => { (context.adapters.supabase.user.getUserIdByWallet as jest.Mock).mockReturnValue(null); - (context.adapters.supabase.wallet.getWalletByUsername as jest.Mock).mockReturnValue(null); + (context.adapters.supabase.wallet.getWalletByUserId as jest.Mock).mockReturnValue(null); context.config.evmPrivateEncrypted = cypherText; (context.adapters.supabase.user.getUserIdByWallet as jest.Mock).mockReturnValue(null); - await expect(generateErc721PermitSignature("tester", "contribution", context)).rejects.toThrow("No wallet found for" + " user"); + await expect(generateErc721PermitSignature(123, "contribution", context)).rejects.toThrow("No wallet found for" + " user"); expect(context.logger.error).toHaveBeenCalledWith("No wallet found for user"); }); }); diff --git a/tests/generate-payout-permit.test.ts b/tests/generate-payout-permit.test.ts index e5055a7..7819541 100644 --- a/tests/generate-payout-permit.test.ts +++ b/tests/generate-payout-permit.test.ts @@ -58,13 +58,13 @@ describe("generatePayoutPermit", () => { { type: "ERC20", amount: 100, - username: "username", + userId: 123, contributionType: "ISSUE", }, { type: "ERC20", amount: 100, - username: "username", + userId: 123, contributionType: "ISSUE", }, ]); diff --git a/yarn.lock b/yarn.lock index b7630d1..b7f035e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2460,17 +2460,17 @@ ignore "^5.1.8" p-map "^4.0.0" -"@supabase/functions-js@2.1.5": - version "2.1.5" - resolved "https://registry.yarnpkg.com/@supabase/functions-js/-/functions-js-2.1.5.tgz#ed1b85f499dfda21d40fe39b86ab923117cb572b" - integrity sha512-BNzC5XhCzzCaggJ8s53DP+WeHHGT/NfTsx2wUSSGKR2/ikLFQTBCDzMvGz/PxYMqRko/LwncQtKXGOYp1PkPaw== +"@supabase/auth-js@2.63.0": + version "2.63.0" + resolved "https://registry.yarnpkg.com/@supabase/auth-js/-/auth-js-2.63.0.tgz#41ff746a50a916208c1f2c6898deacf92c6d0b91" + integrity sha512-yIgcHnlgv24GxHtVGUhwGqAFDyJkPIC/xjx7HostN08A8yCy8HIfl4JEkTKyBqD1v1L05jNEJOUke4Lf4O1+Qg== dependencies: "@supabase/node-fetch" "^2.6.14" -"@supabase/gotrue-js@2.62.2": - version "2.62.2" - resolved "https://registry.yarnpkg.com/@supabase/gotrue-js/-/gotrue-js-2.62.2.tgz#9f15a451559d71475c953aa0027e1248b0210196" - integrity sha512-AP6e6W9rQXFTEJ7sTTNYQrNf0LCcnt1hUW+RIgUK+Uh3jbWvcIST7wAlYyNZiMlS9+PYyymWQ+Ykz/rOYSO0+A== +"@supabase/functions-js@2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@supabase/functions-js/-/functions-js-2.2.2.tgz#53a22d9f1fc770d96c9ad8c9dba5eda339b305f5" + integrity sha512-sJGq1nludmi7pY/fdtCpyY/pYonx7MfHdN408bqb736guWcVI1AChYVbI4kUM978EuOE4Ci6l7bUudfGg07QRw== dependencies: "@supabase/node-fetch" "^2.6.14" @@ -2481,10 +2481,10 @@ dependencies: whatwg-url "^5.0.0" -"@supabase/postgrest-js@1.9.2": - version "1.9.2" - resolved "https://registry.yarnpkg.com/@supabase/postgrest-js/-/postgrest-js-1.9.2.tgz#39c839022ce73f4eb5da6fb7724fb6a6392150c7" - integrity sha512-I6yHo8CC9cxhOo6DouDMy9uOfW7hjdsnCxZiaJuIVZm1dBGTFiQPgfMa9zXCamEWzNyWRjZvupAUuX+tqcl5Sw== +"@supabase/postgrest-js@1.15.0": + version "1.15.0" + resolved "https://registry.yarnpkg.com/@supabase/postgrest-js/-/postgrest-js-1.15.0.tgz#2218c8885a596835b85971f09ea87d1d8353c0c5" + integrity sha512-U4bwBOrhsXWqDjZiYNbVqMBtRGgIIYE0kE5ZNSwsIbeBWfr/UxOMrnkIQUBGIZRhpYW/tw1WnTdRl1AGNyaxcw== dependencies: "@supabase/node-fetch" "^2.6.14" @@ -2505,15 +2505,15 @@ dependencies: "@supabase/node-fetch" "^2.6.14" -"@supabase/supabase-js@^2.39.7": - version "2.39.8" - resolved "https://registry.yarnpkg.com/@supabase/supabase-js/-/supabase-js-2.39.8.tgz#2d8935438bdd6add82484ecd46edb0cd5b3f8c38" - integrity sha512-WpiawHjseIRcCQTZbMJtHUSOepz5+M9qE1jP9BDmg8X7ehALFwgEkiKyHAu59qm/pKP2ryyQXLtu2XZNRbUarw== +"@supabase/supabase-js@2.42.0": + version "2.42.0" + resolved "https://registry.yarnpkg.com/@supabase/supabase-js/-/supabase-js-2.42.0.tgz#9e739cd96989acb0cbaab16da3717400b2ac92fa" + integrity sha512-1PDqJiA4iG45w3AAu6xkccJ3wPqlGJUoz9CPhScRLLTStxhewYhz0mjryTpXz1kgtNHdUAsirALreezn8UZMjA== dependencies: - "@supabase/functions-js" "2.1.5" - "@supabase/gotrue-js" "2.62.2" + "@supabase/auth-js" "2.63.0" + "@supabase/functions-js" "2.2.2" "@supabase/node-fetch" "2.6.15" - "@supabase/postgrest-js" "1.9.2" + "@supabase/postgrest-js" "1.15.0" "@supabase/realtime-js" "2.9.3" "@supabase/storage-js" "2.5.5"