decode method

  1. @override
void decode(
  1. MessagePayload? payload
)
override

Implementation

@override
void decode(MessagePayload? payload) {
  super.decode(payload);
  if (payload?.binaryContent != null) {
    thumbnail = decodeJpg(payload?.binaryContent ?? []);
  }
  if (payload?.content != null) {
    var map = json.decode(payload!.content!);
    duration = map['duration'];
    duration ??= map['d'];
  }
}