From 13b6b83f6ab4a339fcc3567c465193bb2f4b211a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois-X=2E=20T=2E?= Date: Tue, 12 May 2026 16:28:36 -0400 Subject: [PATCH] fix app build --- apps/app/src/api/ads.rs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/apps/app/src/api/ads.rs b/apps/app/src/api/ads.rs index 0a3028e1db..f6c699e62b 100644 --- a/apps/app/src/api/ads.rs +++ b/apps/app/src/api/ads.rs @@ -17,13 +17,11 @@ pub struct AdsState { const AD_LINK: &str = "https://modrinth.com/wrapper/app-ads-cookie"; #[cfg(not(target_os = "linux"))] -const APP_VERSION: &str = env!("CARGO_PKG_VERSION"); -#[cfg(not(target_os = "linux"))] const ADS_USER_AGENT: &str = concat!( "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 ", "(KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36 ", "ModrinthApp/", - APP_VERSION, + env!("CARGO_PKG_VERSION"), " (Modrinth App)", ); @@ -36,14 +34,14 @@ fn ads_user_agent_override_params() -> String { "brands": [ { "brand": "Chromium", "version": "128" }, { "brand": "Google Chrome", "version": "128" }, - { "brand": "Modrinth App", "version": APP_VERSION }, + { "brand": "Modrinth App", "version": env!("CARGO_PKG_VERSION") }, { "brand": "Not=A?Brand", "version": "99" }, ], "fullVersion": "128.0.0.0", "fullVersionList": [ { "brand": "Chromium", "version": "128.0.0.0" }, { "brand": "Google Chrome", "version": "128.0.0.0" }, - { "brand": "Modrinth App", "version": APP_VERSION }, + { "brand": "Modrinth App", "version": env!("CARGO_PKG_VERSION") }, { "brand": "Not=A?Brand", "version": "99.0.0.0" }, ], "platform": "Windows",