Created
March 23, 2024 15:32
-
-
Save SergeiMikhailovskii/0ca381e036ade8d7203c6dbcd75078d9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class AmazonInAppReviewInitParams(val context: Context) | |
class AmazonInAppReviewManager( | |
private val params: AmazonInAppReviewInitParams | |
) : InAppReviewDelegate { | |
override fun requestInAppReview() = flow { | |
val context = params.context | |
context.openMarket( | |
deeplink = "amzn://apps/android?p=${context.packageName}", | |
url = "https://www.amazon.com/gp/mas/dl/android?p=${context.packageName}" | |
) | |
emit(ReviewCode.NO_ERROR) | |
} | |
override fun requestInMarketReview() = requestInAppReview() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment