Have app send download analytics meta (#5954)

* wip: add download reasons to app

* update how download meta is gathered

* cargo fmt

* prepr frontend
This commit is contained in:
aecsocket
2026-04-30 20:55:47 +01:00
committed by GitHub
parent 38a39feef1
commit 1875b89556
20 changed files with 195 additions and 32 deletions

View File

@@ -109,6 +109,7 @@ pub async fn profile_create(
let fetched = crate::util::fetch::fetch(
icon,
None,
None,
&state.fetch_semaphore,
&state.pool,
)

View File

@@ -461,6 +461,7 @@ pub async fn update_project(
let mut path = Profile::add_project_version(
profile_path,
update_version,
fetch::DownloadReason::Standalone,
&state.pool,
&state.fetch_semaphore,
&state.io_semaphore,
@@ -501,11 +502,14 @@ pub async fn update_project(
pub async fn add_project_from_version(
profile_path: &str,
version_id: &str,
reason: fetch::DownloadReason,
) -> crate::Result<String> {
let state = State::get().await?;
let project_path = Profile::add_project_version(
profile_path,
version_id,
reason,
&state.pool,
&state.fetch_semaphore,
&state.io_semaphore,