Skip to content

src/default-handle.ts

11 lines · 339 B · TypeScript
Raw
import { getDefaultHandle, setDefaultHandle, tryDefaultHandle } from './client.ts'

/**
 * Read the Bluesky handle from this package's storage.
 */
export default async function defaultHandle() {
	const handle = await tryDefaultHandle()
	return { handle: handle || null }
}

export { getDefaultHandle, setDefaultHandle, tryDefaultHandle }