Commit 2fa8bc7f authored by Mygod's avatar Mygod

Refine #1500

parent 94527ea4
...@@ -76,7 +76,7 @@ class ProfilesFragment : ToolbarFragment(), Toolbar.OnMenuItemClickListener { ...@@ -76,7 +76,7 @@ class ProfilesFragment : ToolbarFragment(), Toolbar.OnMenuItemClickListener {
} }
@SuppressLint("ValidFragment") @SuppressLint("ValidFragment")
public class QRCodeDialog() : DialogFragment() { private class QRCodeDialog() : DialogFragment() {
constructor(url: String) : this() { constructor(url: String) : this() {
val bundle = Bundle() val bundle = Bundle()
...@@ -106,9 +106,9 @@ class ProfilesFragment : ToolbarFragment(), Toolbar.OnMenuItemClickListener { ...@@ -106,9 +106,9 @@ class ProfilesFragment : ToolbarFragment(), Toolbar.OnMenuItemClickListener {
override fun onDetach() { override fun onDetach() {
super.onDetach() super.onDetach()
if (activity != null && !activity!!.isFinishing() && !activity!!.isDestroyed) { val activity = activity
if (activity != null && !activity.isFinishing && !activity.isDestroyed)
adapter?.setNdefPushMessage(null, activity) adapter?.setNdefPushMessage(null, activity)
}
adapter = null adapter = null
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment