Updated on 2026-08-14

This commit is contained in:
Tangem 2025-07-15 13:37:46 +05:00
parent 135a8a22f0
commit 142e57868d
3 changed files with 18 additions and 8 deletions

View file

@ -1,5 +1,6 @@
package com.tangem.core.deeplink.converter
import android.os.Bundle
import com.tangem.common.routing.DeepLinkRoute
import com.tangem.common.routing.DeepLinkScheme
import com.tangem.core.deeplink.DEEPLINK_KEY
@ -22,6 +23,18 @@ object PayloadToDeeplinkConverter : Converter<Map<String, String>, String?> {
}
}
fun convertBundle(bundle: Bundle?): String? {
if (bundle == null) return null
val bundleDataMap = mutableMapOf<String, String>()
for (key in bundle.keySet()) {
val value = bundle.getString(key)
if (value != null) {
bundleDataMap[key] = value
}
}
return convert(bundleDataMap)
}
@Suppress("ReturnCount")
private fun buildNotificationDeeplink(payload: Map<String, String>): String? {
val type = payload[TYPE_KEY] ?: return null