如何设置google应用内评论可选?

How to set the google in-app comment optional?

应用内对话框在我的设备上运行良好,但它需要评论。如果用户没有输入评论,提交按钮将不会启用。我希望用户对应用只有可选的评论。

fun inAppReview() {
    val reviewManager = ReviewManagerFactory.create(mContext)
    val requestReviewFlow = reviewManager.requestReviewFlow()
    requestReviewFlow.addOnCompleteListener { request ->
        if (request.isSuccessful) {
            // We got the ReviewInfo object
            val reviewInfo = request.result
            val flow = reviewManager.launchReviewFlow(mContext as Activity, reviewInfo)
            flow.addOnCompleteListener {
                // The flow has finished. The API does not indicate whether the user
                // reviewed or not, or even whether the review dialog was shown. Thus, no
                // matter the result, we continue our app flow.
            }
        } else {
            Log.d("Error: ", request.exception.toString())
            // There was some problem, continue regardless of the result.
        }
    }
}

依赖关系

implementation 'com.google.android.play:core:1.8.0'
implementation 'com.google.android.play:core-ktx:1.8.1'

如对类似问题的回答所述:仅当您是测试人员时才需要。既然,写着“reviews are only visible to developers”,那就说明你才是真正的测试者。在其他情况下,它将是可选的,如文档中所述。