resetPasswordUrl property

String get resetPasswordUrl

The URL for the reset password page for this CarpService.

Implementation

String get resetPasswordUrl {
  String url = "${_app!.uri}";
  String host = '';
  if (url.contains('dev')) host = 'dev';
  if (url.contains('test')) host = 'test';
  if (url.contains('stage')) host = 'stage';
  if (host.isNotEmpty) {
    String rawUri = url.substring(0, url.indexOf(host));
    url = '${rawUri}portal/$host';
  }
  url += '/forgotten';

  print('url = $url');

  return url;
}