mirror of
https://github.com/SableClient/Sable.git
synced 2026-12-04 07:42:24 -08:00
Centralize Matrix SDK imports behind a local compatibility module, migrate matrix subpath imports to the boundary, and switch to the $types alias. Upgrade TypeScript to latest so matrix-js-sdk typings resolve correctly before the next cleanup phase.
15 lines
347 B
TypeScript
15 lines
347 B
TypeScript
import { CryptoApi } from '$types/matrix-sdk';
|
|
|
|
export const verifiedDevice = async (
|
|
api: CryptoApi,
|
|
userId: string,
|
|
deviceId: string
|
|
): Promise<boolean | null> => {
|
|
const status = await api.getDeviceVerificationStatus(userId, deviceId);
|
|
|
|
if (!status) return null;
|
|
|
|
const verified = status.crossSigningVerified;
|
|
return verified;
|
|
};
|