处理SonarQube问题

This commit is contained in:
leafwai
2022-06-01 10:22:34 +08:00
parent 7e237d963b
commit 7bef39e71a
4 changed files with 9 additions and 15 deletions

View File

@ -73,13 +73,11 @@ public class DataUtils {
});
options.setBeforeBreadcrumb(((breadcrumb, hint) -> {
if ("ui.lifecycle".equals(breadcrumb.getCategory()) && "started".equals(breadcrumb.getData("state"))) {
if (GlobalActivityManager.INSTANCE.getCurrentActivity() instanceof BaseActivity) {
Pair<String, String> businessId = ((BaseActivity) GlobalActivityManager.INSTANCE.getCurrentActivity()).getBusinessId();
if (businessId != null) {
breadcrumb.setData("businessId1", businessId.component1());
breadcrumb.setData("businessId2", businessId.component2());
}
if ("ui.lifecycle".equals(breadcrumb.getCategory()) && "started".equals(breadcrumb.getData("state")) && GlobalActivityManager.INSTANCE.getCurrentActivity() instanceof BaseActivity) {
Pair<String, String> businessId = ((BaseActivity) GlobalActivityManager.INSTANCE.getCurrentActivity()).getBusinessId();
if (businessId != null) {
breadcrumb.setData("businessId1", businessId.component1());
breadcrumb.setData("businessId2", businessId.component2());
}
}
return breadcrumb;

View File

@ -7,14 +7,13 @@ import android.widget.Space
import android.widget.TextView
import androidx.constraintlayout.widget.ConstraintLayout
import androidx.constraintlayout.widget.ConstraintSet
import com.gh.gamecenter.common.base.BaseRecyclerViewHolder
import com.gh.common.databind.BindingAdapters
import com.gh.gamecenter.R
import com.gh.gamecenter.common.base.BaseRecyclerViewHolder
import com.gh.gamecenter.common.utils.dip2px
import com.gh.gamecenter.common.utils.toColor
import com.gh.gamecenter.common.utils.toDrawable
import com.gh.gamecenter.common.view.DrawableView
import com.gh.gamecenter.R
import com.gh.gamecenter.common.utils.goneIf
import com.gh.gamecenter.databinding.GameItemBinding
import com.gh.gamecenter.entity.GameEntity

View File

@ -10,13 +10,12 @@ import androidx.constraintlayout.widget.ConstraintSet
import androidx.recyclerview.widget.RecyclerView
import com.gh.common.databind.BindingAdapters
import com.gh.common.util.DownloadItemUtils
import com.gh.gamecenter.R
import com.gh.gamecenter.adapter.viewholder.GameViewHolder
import com.gh.gamecenter.common.utils.dip2px
import com.gh.gamecenter.common.utils.toColor
import com.gh.gamecenter.common.utils.toDrawable
import com.gh.gamecenter.common.view.AsyncUi
import com.gh.gamecenter.R
import com.gh.gamecenter.adapter.viewholder.GameViewHolder
import com.gh.gamecenter.common.utils.goneIf
import com.gh.gamecenter.entity.GameEntity
import com.gh.gamecenter.entity.SubjectEntity
import com.gh.gamecenter.game.GameItemViewHolder

View File

@ -5,9 +5,7 @@ import android.content.Intent
import android.os.Bundle
import com.gh.gamecenter.common.base.activity.ToolBarActivity
import com.gh.gamecenter.common.constant.EntranceConsts
import com.gh.gamecenter.gamecollection.detail.GameCollectionDetailFragment
import com.gh.gamecenter.gamecollection.detail.conversation.GameCollectionCommentConversationFragment
import com.gh.gamecenter.gamedetail.GameDetailFragment
import com.gh.gamecenter.qa.comment.conversation.CommentConversationFragment
class NewCommentDetailActivity : ToolBarActivity() {