From 83bfc85066762a2d96ffc98e413038d255bc2c08 Mon Sep 17 00:00:00 2001 From: Naomi Plasterer Date: Fri, 1 Dec 2023 17:18:59 -0800 Subject: [PATCH] lint fixing --- example/src/ConversationScreen.tsx | 2 +- src/index.ts | 6 +++--- src/lib/Client.ts | 19 +++++++++++++------ 3 files changed, 17 insertions(+), 10 deletions(-) diff --git a/example/src/ConversationScreen.tsx b/example/src/ConversationScreen.tsx index 9a6e89809..b6e92a649 100644 --- a/example/src/ConversationScreen.tsx +++ b/example/src/ConversationScreen.tsx @@ -34,6 +34,7 @@ import { } from 'xmtp-react-native-sdk' import { NavigationParamList } from './Navigation' +import { useXmtp } from './XmtpContext' import { useConversation, useMessage, @@ -42,7 +43,6 @@ import { useLoadRemoteAttachment, usePrepareRemoteAttachment, } from './hooks' -import { useXmtp } from './XmtpContext' type Attachment = { file?: DocumentPickerAsset diff --git a/src/index.ts b/src/index.ts index da5f08123..72f0b1940 100644 --- a/src/index.ts +++ b/src/index.ts @@ -92,10 +92,10 @@ export async function canMessage( export async function staticCanMessage( peerAddress: string, - environment: "local" | "dev" | "production", - appVersion?: string | undefined, + environment: 'local' | 'dev' | 'production', + appVersion?: string | undefined ): Promise { - return await XMTPModule.staticCanMessage(peerAddress, environment, appVersion); + return await XMTPModule.staticCanMessage(peerAddress, environment, appVersion) } export async function encryptAttachment( diff --git a/src/lib/Client.ts b/src/lib/Client.ts index a5e00cd38..f1b44132c 100644 --- a/src/lib/Client.ts +++ b/src/lib/Client.ts @@ -35,7 +35,7 @@ export class Client { * @param {Signer} signer - The signer object used for authentication and message signing. * @param {Partial} opts - Optional configuration options for the Client. * @returns {Promise} A Promise that resolves to a new Client instance. - * + * * See {@link https://xmtp.org/docs/build/authentication#create-a-client | XMTP Docs} for more information. */ static async create< @@ -155,16 +155,23 @@ export class Client { /** * Static method to determine if the address is currently in our network. - * + * * This method checks if the specified peer has signed up for XMTP. - * + * * @param {string} peerAddress - The address of the peer to check for messaging eligibility. * @param {Partial} opts - Optional configuration options for the Client. * @returns {Promise} */ - static async canMessage(peerAddress: string, opts?: Partial): Promise { - const options = defaultOptions(opts); - return await XMTPModule.staticCanMessage(peerAddress, options.env, options.appVersion); + static async canMessage( + peerAddress: string, + opts?: Partial + ): Promise { + const options = defaultOptions(opts) + return await XMTPModule.staticCanMessage( + peerAddress, + options.env, + options.appVersion, + ) } constructor(