forked from
mary.my.id/atcute
a collection of lightweight TypeScript packages for AT Protocol, the protocol powering Bluesky
1/**
2 * thrown when an MST key is invalid or malformed
3 */
4export class InvalidMstKeyError extends Error {
5 constructor(public key: string) {
6 super(`invalid mst key; key=${key}`);
7 }
8}
9
10/**
11 * thrown when a referenced block cannot be found in the store
12 */
13export class MissingBlockError extends Error {
14 constructor(
15 public cid: string,
16 public def?: string,
17 ) {
18 super(`missing block in store; cid=${cid}` + (def ? `; type=${def}` : ``));
19 }
20}