diff --git a/app/src/main/java/com/hover/stax/hover/TransactionReceiver.kt b/app/src/main/java/com/hover/stax/hover/TransactionReceiver.kt index 68cc29b4c..c89eed7b8 100644 --- a/app/src/main/java/com/hover/stax/hover/TransactionReceiver.kt +++ b/app/src/main/java/com/hover/stax/hover/TransactionReceiver.kt @@ -190,7 +190,9 @@ class TransactionReceiver : BroadcastReceiver(), KoinComponent { } private suspend fun parseAccounts(ussdAccountList: String) { - val pattern = Pattern.compile("^([\\d]{1,2})[>):.\\s]+(.+)\$", Pattern.MULTILINE) + var splitterPattern = action?.getStepByVar("accountName")?.optString("valid_response_regex") + if (splitterPattern == null) splitterPattern = "^\\s*([\\d]{1,2})[>):.\\s]+(.+)$" + val pattern = Pattern.compile(splitterPattern, Pattern.MULTILINE) val matcher = pattern.matcher(ussdAccountList) while (matcher.find()) { diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 184b4c4b7..38dce5a17 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -86,7 +86,7 @@ glide = { module = "com.github.bumptech.glide:glide", version.ref = "glide" } glide-compiler = { module = "com.github.bumptech.glide:compiler", version.ref = "glide" } coil = "io.coil-kt:coil-compose:2.2.2" -hover = "com.hover:android-sdk:2.0.0-beta01" +hover = "com.hover:android-sdk:2.0.0-beta03" volley = "com.android.volley:volley:1.2.1" play-services = "com.google.android.gms:play-services-analytics:18.0.2" picasso = "com.squareup.picasso:picasso:2.71828"