Skip to content

Commit b08db98

Browse files
lucasloispcodex
andcommitted
Limit app identifier fallback to Windows
Committed-By-Agent: codex Co-authored-by: codex <noreply@openai.com>
1 parent 9291cec commit b08db98

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

SDK/Runtime/Networking/HttpRequestHandler.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,14 @@ IClientAnalyticsIdRepository clientAnalyticsIdRepository
2929
_clientId = privyConfig.ClientId;
3030
_baseUrl = $"{PrivyEnvironment.BASE_URL}/api/v1";
3131
_clientAnalyticsIdRepository = clientAnalyticsIdRepository;
32-
// Unity's Application.identifier can be empty for some standalone builds (or not set in Player Settings).
33-
// The backend expects a native app identifier header for mobile/desktop clients, so we provide a fallback.
3432
_appIdentifier = !string.IsNullOrEmpty(Application.identifier)
3533
? Application.identifier
34+
#if UNITY_STANDALONE_WIN || UNITY_EDITOR_WIN
35+
// Windows standalone builds may not have Application.identifier configured.
3636
: Application.productName;
37+
#else
38+
: null;
39+
#endif
3740

3841
PrivyLogger.Debug($"App identifier is {_appId}");
3942
PrivyLogger.Debug($"Unity app identifier is {_appIdentifier}");

0 commit comments

Comments
 (0)