getAdInfoById method

MaxAdInfoBean? getAdInfoById(
  1. String id
)

Implementation

MaxAdInfoBean? getAdInfoById(String id){
  var indexWhere2 = _maxAdBean.secondRewardedAdList.indexWhere((element) => element.id==id);
  if(indexWhere2>=0){
    return _maxAdBean.secondRewardedAdList[indexWhere2];
  }
  var indexWhere3 = _maxAdBean.secondInterAdList.indexWhere((element) => element.id==id);
  if(indexWhere3>=0){
    return _maxAdBean.secondInterAdList[indexWhere3];
  }
  return null;
}