modifyInsurance method

Future<Insurance> modifyInsurance(
  1. String sdkId,
  2. Insurance insurance
)

Implementation

Future<Insurance> modifyInsurance(String sdkId, Insurance insurance) async {
	final res = await _methodChannel.invokeMethod<String>(
		'InsuranceApi.modifyInsurance',
		{
			"sdkId": sdkId,
			"insurance": jsonEncode(Insurance.encode(insurance)),
		}
	);
	if (res == null) throw AssertionError("received null result from platform method modifyInsurance");
	final parsedResJson = jsonDecode(res);
	return Insurance.fromJSON(parsedResJson);
}