initMock method

dynamic initMock({
  1. List<RequestModel> getRequestModels()?,
})

Implementation

initMock({List<RequestModel> Function()? getRequestModels}) async {
  this.getRequestModels = getRequestModels;
  final source = await saveManager.getString(mockApiKey);
  if (isNotNullOrEmpty(source)) {
    mockApis = MockApiSaver.fromJson(jsonDecode(source!)).data ?? {};
  }
}