fix: app user agent for api-client reqs using tauri http plugin (#6045)

fix: app user agent
This commit is contained in:
Calum H.
2026-05-08 20:52:52 +01:00
committed by GitHub
parent 7048a35e9f
commit a082e8597c
9 changed files with 80 additions and 66 deletions

View File

@@ -146,8 +146,9 @@ const popupNotificationManager = new AppPopupNotificationManager()
providePopupNotificationManager(popupNotificationManager)
const { addPopupNotification } = popupNotificationManager
const appVersion = getVersion()
const tauriApiClient = new TauriModrinthClient({
userAgent: `modrinth/theseus/${getVersion()} (support@modrinth.com)`,
userAgent: async () => `modrinth/theseus/${await appVersion} (support@modrinth.com)`,
labrinthBaseUrl: config.labrinthBaseUrl,
archonBaseUrl: config.archonBaseUrl,
features: [