From 035bc8105c02b6455fb73109e2364f05d0e7ee67 Mon Sep 17 00:00:00 2001 From: Ben Dean-Kawamura Date: Fri, 5 Jun 2026 09:29:38 -0400 Subject: [PATCH] ads-client: Use `AdsClientUrl` consistently I'm working on a new UniFFI parser (https://github.com/mozilla/uniffi-rs/pull/2841) and it currently requires that the type name in exported functions match the one used in the `custom_type!` macro. I could probably rework the parser to handle the type alias, but this way feels cleaner to me anyways. Feel free to push back if you don't like this change though. --- components/ads-client/src/ffi.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/components/ads-client/src/ffi.rs b/components/ads-client/src/ffi.rs index dccd93aae8..ba50352fdc 100644 --- a/components/ads-client/src/ffi.rs +++ b/components/ads-client/src/ffi.rs @@ -20,10 +20,10 @@ use crate::mars::ad_response::{ }; use crate::mars::Environment; use crate::mars::ReportReason; +use crate::AdsClientUrl; use crate::MozAdsClient; use parking_lot::Mutex; use std::collections::HashMap; -use url::Url; pub use error::{AdsClientApiResult, MozAdsClientApiError}; pub use telemetry::MozAdsTelemetry; @@ -93,9 +93,9 @@ pub struct MozAdsPlacementRequestWithCount { #[derive(Debug, PartialEq, uniffi::Record)] pub struct MozAdsCallbacks { - pub click: Url, - pub impression: Url, - pub report: Option, + pub click: AdsClientUrl, + pub impression: AdsClientUrl, + pub report: Option, } #[derive(uniffi::Object)]