mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-10-31 08:15:02 +00:00
Generate null MapTiler BuildConfig values when not provided
Remove the default values from the Gradle file, the public MapTiler defaults are now only defined in MapTilerDefaults. buildConfigFieldStr now accepts a null value. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -10,14 +10,17 @@ package extension
|
||||
|
||||
import com.android.build.api.dsl.VariantDimension
|
||||
|
||||
/**
|
||||
* Adds a String field to the generated BuildConfig class. If [value] is null, the field will be null.
|
||||
*/
|
||||
fun VariantDimension.buildConfigFieldStr(
|
||||
name: String,
|
||||
value: String,
|
||||
value: String?,
|
||||
) {
|
||||
buildConfigField(
|
||||
type = "String",
|
||||
name = name,
|
||||
value = "\"$value\""
|
||||
value = value?.let { "\"$it\"" } ?: "null"
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user