getCurrentRoute method

String getCurrentRoute()

Implementation

String getCurrentRoute() {
  if (routeHistory.isNotEmpty) {
    String lastContent = routeHistory.last;
    debugPrint("Last Content: $lastContent");
    return lastContent;
  } else {
    // Handle the case when 'routeHistory' is empty
    debugPrint("routeHistory is empty");
    return "";
  }
}