API reference › @evolu/common › local‑first/Protocol › ProtocolInvalidDataError
Defined in: packages/common/src/local-first/Protocol.ts:524
Error for a malformed ProtocolMessage or EncryptedDbChange,
with the decoding error as error. It holds none of the message's bytes, so
it carries no OwnerId or write key.
A protocol message is decoded whole before any of it is applied, so a malformed one has no effect, and a relay does not reply to it. A message of a type its receiver does not accept, such as a Request sent to a client, is malformed too. A throw while applying a decoded message is a defect, not this error.
Extends
Typed<"ProtocolInvalidDataError">
Properties
error
readonly error: unknown;
Defined in: packages/common/src/local-first/Protocol.ts:525
type
readonly type: "ProtocolInvalidDataError";
Defined in: packages/common/src/Type.ts:19326