Skip to content

Commit 3015a98

Browse files
runningcodeclaude
authored andcommitted
Ref(android-distribution): Remove main_binary_identifier parameter (EME-391) (#4773)
Removes the redundant main_binary_identifier parameter from the Build Distribution API calls, as it was always set to the same value as app_id. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude <[email protected]>
1 parent 5da8e83 commit 3015a98

File tree

3 files changed

+1
-5
lines changed

3 files changed

+1
-5
lines changed

sentry-android-distribution/src/main/java/io/sentry/android/distribution/DistributionHttpClient.kt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ internal class DistributionHttpClient(private val options: SentryOptions) {
2222

2323
/** Parameters for checking updates. */
2424
data class UpdateCheckParams(
25-
val mainBinaryIdentifier: String,
2625
val appId: String,
2726
val platform: String = "android",
2827
val versionCode: Long,
@@ -53,8 +52,7 @@ internal class DistributionHttpClient(private val options: SentryOptions) {
5352
append(
5453
"/api/0/projects/${URLEncoder.encode(orgSlug, "UTF-8")}/${URLEncoder.encode(projectSlug, "UTF-8")}/preprodartifacts/check-for-updates/"
5554
)
56-
append("?main_binary_identifier=${URLEncoder.encode(params.mainBinaryIdentifier, "UTF-8")}")
57-
append("&app_id=${URLEncoder.encode(params.appId, "UTF-8")}")
55+
append("?app_id=${URLEncoder.encode(params.appId, "UTF-8")}")
5856
append("&platform=${URLEncoder.encode(params.platform, "UTF-8")}")
5957
append("&build_number=${URLEncoder.encode(params.versionCode.toString(), "UTF-8")}")
6058
append("&build_version=${URLEncoder.encode(params.versionName, "UTF-8")}")

sentry-android-distribution/src/main/java/io/sentry/android/distribution/DistributionIntegration.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,6 @@ public class DistributionIntegration(context: Context) : Integration, IDistribut
133133
val appId = context.applicationInfo.packageName
134134

135135
DistributionHttpClient.UpdateCheckParams(
136-
mainBinaryIdentifier = appId,
137136
appId = appId,
138137
platform = "android",
139138
versionCode = versionCode,

sentry-android-distribution/src/test/java/io/sentry/android/distribution/DistributionHttpClientTest.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ class DistributionHttpClientTest {
3434
fun `test checkForUpdates with real API`() {
3535
val params =
3636
DistributionHttpClient.UpdateCheckParams(
37-
mainBinaryIdentifier = "com.emergetools.hackernews",
3837
appId = "com.emergetools.hackernews",
3938
versionName = "1.0.0",
4039
versionCode = 5L,

0 commit comments

Comments
 (0)