onPressCalendar method Null safety

dynamic onPressCalendar()

달력을 눌렀을때

Implementation

onPressCalendar() async {
  LogManager().addLog("달력선택", action: LogConstants.buttonTap, screen: runtimeType.toString());
  DateTime? _dateTime = await Navigator.of(ApiService().context, rootNavigator: true)
      .pushNamed(DateTimePickerScreen.routeName, arguments: DateTimePickerScreenArguments(currentDateTime: selectedDateTime)) as DateTime?;

  // 날짜를 선택했을때만 실행
  if (_dateTime != null) {
    selectedDateTime = _dateTime;
    selectedDateTime = Helper().convertDateTimeToMidnight(selectedDateTime);
    notifyListeners();
    refreshController.refreshToIdle();
    requestRefresh();
    LogManager().addLog("달력날짜선택 - $selectedDateTime", action: LogConstants.buttonTap, screen: runtimeType.toString());
  }
}