Skip to content

Commit

Permalink
improve code
Browse files Browse the repository at this point in the history
  • Loading branch information
Quentin Marciset authored and quentinmarciset committed Oct 14, 2022
1 parent f651f31 commit a277f7d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion android/Formatters/HtmlText.kt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ fun htmlText(view: TextView, htmlText: String?) {
webView.setPadding(view.paddingStart, view.paddingTop, view.paddingEnd, view.paddingBottom)
webView.layoutParams = view.layoutParams
webView.loadDataWithBaseURL(null, htmlText, "text/html", "utf-8", null)
(view.parent as ViewGroup?)?.addView(webView)
(view.parent as? ViewGroup)?.addView(webView)
view.visibility = View.GONE
}

0 comments on commit a277f7d

Please sign in to comment.