Update user agent from Mapbox to MapLibreNative (#2367)

This commit is contained in:
Bart Louwers
2024-05-07 23:48:15 +02:00
committed by GitHub
parent d537c7e525
commit d4e2fd9102
6 changed files with 8 additions and 7 deletions

View File

@@ -51,10 +51,7 @@ android {
targetSdkVersion 33
buildConfigField "String", "GIT_REVISION_SHORT", String.format("\"%s\"", getGitRevision())
buildConfigField "String", "GIT_REVISION", String.format("\"%s\"", getGitRevision(false))
buildConfigField "String", "MAPBOX_SDK_IDENTIFIER", String.format("\"%s\"", "mapbox-maps-android")
buildConfigField "String", "MAPBOX_SDK_VERSION", String.format("\"%s\"", project.VERSION_NAME)
buildConfigField "String", "MAPBOX_VERSION_STRING", String.format("\"Mapbox/%s\"", project.VERSION_NAME)
buildConfigField "String", "MAPBOX_EVENTS_USER_AGENT", String.format("\"mapbox-maps-android/%s\"", project.VERSION_NAME)
buildConfigField "String", "MAPLIBRE_VERSION_STRING", String.format("\"MapLibre Native/%s\"", project.VERSION_NAME)
consumerProguardFiles 'proguard-rules.pro'
externalNativeBuild {

View File

@@ -41,7 +41,7 @@ public class HttpRequestImpl implements HttpRequest {
private static final String userAgentString = toHumanReadableAscii(
String.format("%s %s (%s) Android/%s (%s)",
HttpIdentifier.getIdentifier(),
BuildConfig.MAPBOX_VERSION_STRING,
BuildConfig.MAPLIBRE_VERSION_STRING,
BuildConfig.GIT_REVISION_SHORT,
Build.VERSION.SDK_INT,
Build.CPU_ABI)