diff --git a/examples/optimizing-programmatically-using-json-example/app/src/main/java/com/thunderhead/optimizationexample/MainActivity.kt b/examples/optimizing-programmatically-using-json-example/app/src/main/java/com/thunderhead/optimizationexample/MainActivity.kt index d42fbb3..c302676 100644 --- a/examples/optimizing-programmatically-using-json-example/app/src/main/java/com/thunderhead/optimizationexample/MainActivity.kt +++ b/examples/optimizing-programmatically-using-json-example/app/src/main/java/com/thunderhead/optimizationexample/MainActivity.kt @@ -1,7 +1,6 @@ package com.thunderhead.optimizationexample import android.os.Bundle -import android.text.Html import android.util.Base64 import android.util.Log import android.view.LayoutInflater @@ -160,15 +159,13 @@ class FirstFragment : Fragment() { actions?.run { this.filter { it.getString("name").contains("banner") } .map { it.getJSONObject("asset").getString("content") } - .map { content -> JSONObject(Html.fromHtml(content).toString()) } - .forEach { contentJson -> updateContent(contentJson, true) } + .forEach { contentJson -> updateContent(JSONObject(contentJson), true) } } actions?.run { this.filter { it.getString("name").contains("card") } .map { it.getJSONObject("asset").getString("content") } - .map { content -> JSONObject(Html.fromHtml(content).toString()) } - .forEach { contentJson -> updateContent(contentJson, false) } + .forEach { contentJson -> updateContent(JSONObject(contentJson), false) } } } diff --git a/examples/optimizing-programmatically-using-json-example/app/src/main/res/xml/network_security_config.xml b/examples/optimizing-programmatically-using-json-example/app/src/main/res/xml/network_security_config.xml index f04aad3..ba4d81f 100644 --- a/examples/optimizing-programmatically-using-json-example/app/src/main/res/xml/network_security_config.xml +++ b/examples/optimizing-programmatically-using-json-example/app/src/main/res/xml/network_security_config.xml @@ -1,3 +1,4 @@ +