SignedDocumentModel.fromJson constructor

SignedDocumentModel.fromJson(
  1. Map<String, dynamic> json,
  2. dynamic fileName
)

Implementation

factory SignedDocumentModel.fromJson(Map<String, dynamic> json, fileName) {
  if (json["code"] != 200) {
    throw Exception(json["message"]);
  }
  return SignedDocumentModel._(
    fileBase64: json["response"]["file"],
    fileName: fileName,
  );
}