"use server";

import {createSessionClient} from "@/lib/backend/server-appwrite";

export async function useUser() {
    try {
        const {account} = await createSessionClient();
        return await account.get();
    } catch (error) {
        return null;
    }
}