buildUrl method

String buildUrl()

Implementation

String buildUrl() {
  final params = <String, String>{};

  if (apiKey != null) {
    params['key'] = apiKey!;
  }

  return url.replace(queryParameters: params).toString();
}