[6.0.0] fix chain log param without gson,which has impl gson func

This commit is contained in:
zhongchao
2023-08-21 15:17:25 +08:00
parent 0e72c6571d
commit 486542872e
4 changed files with 58 additions and 73 deletions

View File

@@ -371,12 +371,12 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
nodeAliasCode = CHAIN_CODE_HTTP_DNS_ERROR_REASON,
paramIndexes = [0]
)
private fun logError(pr: String) {
private fun logError(pr: Map<String,Any>) {
CallerLogger.e("$M_MAIN$TAG", "pr:$pr")
}
// 归一处理
private fun getPrReason(msg: String): String {
private fun getPrReason(msg: String): Map<String,Any> {
val map = hashMapOf<String, Any>()
map["lat"] =
if (CallerChassisLocationGCJ02ListenerManager.getChassisLocationGCJ02().latitude != 0.0)
@@ -387,7 +387,7 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
CallerChassisLocationGCJ02ListenerManager.getChassisLocationGCJ02().longitude else
CallerMapUIServiceManager.getGDLocationServer(context!!)!!.lastLon
map["reason"] = msg
return GsonUtils.toJson(map)
return map
}
@ChainLog(