From c464d3bc906497c2d0ef125d891132c534ff65b4 Mon Sep 17 00:00:00 2001 From: Maximilian Salomon Date: Mon, 5 Feb 2024 01:57:28 +0100 Subject: [PATCH] downgrade to mathparser v4 because of license clash with f-droid fixes #55 --- app/build.gradle.kts | 4 ++-- .../de/salomax/currencies/viewmodel/main/MainViewModel.kt | 4 ---- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/app/build.gradle.kts b/app/build.gradle.kts index daf31784..af3927c7 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -106,8 +106,8 @@ dependencies { val moshiVersion = "1.15.1" implementation("com.squareup.moshi:moshi-kotlin:$moshiVersion") ksp("com.squareup.moshi:moshi-kotlin-codegen:$moshiVersion") - // math - implementation("org.mariuszgromada.math:MathParser.org-mXparser:5.2.1") + // math (v5 releases use incompatible license to fdroid: noinspection GradleDependency) + implementation("org.mariuszgromada.math:MathParser.org-mXparser:4.4.3") // charts implementation("com.robinhood.spark:spark:1.2.0") // test diff --git a/app/src/main/kotlin/de/salomax/currencies/viewmodel/main/MainViewModel.kt b/app/src/main/kotlin/de/salomax/currencies/viewmodel/main/MainViewModel.kt index 6c3d766c..dd5b4454 100644 --- a/app/src/main/kotlin/de/salomax/currencies/viewmodel/main/MainViewModel.kt +++ b/app/src/main/kotlin/de/salomax/currencies/viewmodel/main/MainViewModel.kt @@ -13,7 +13,6 @@ import de.salomax.currencies.util.getDecimalSeparator import de.salomax.currencies.util.hasAppendedCurrencySymbol import de.salomax.currencies.util.toHumanReadableNumber import org.mariuszgromada.math.mxparser.Expression -import org.mariuszgromada.math.mxparser.License import java.text.Collator import java.time.LocalDate import java.time.ZoneId @@ -63,9 +62,6 @@ class MainViewModel(val app: Application, onlyCache: Boolean = false) : AndroidV */ init { - // MathParser.org-mXparser TOS - License.iConfirmNonCommercialUse("Salomax") - // only update if data is old: https://github.com/Formicka/exchangerate.host // "Rates are updated around midnight UTC every working day." val currentDate = LocalDate.now(ZoneId.of("UTC"))