Skip to content

Commit 895fa2e

Browse files
Fix: Change visibility of TrialManager.isPurchased to internal
The previous commit failed to build because MainActivity could not access TrialManager.isPurchased due to it being private. This commit changes the visibility of `TrialManager.isPurchased` from `private` to `internal` to allow access from MainActivity within the same module, resolving the build error.
1 parent 874b42a commit 895fa2e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

app/src/main/kotlin/com/google/ai/sample/TrialManager.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ object TrialManager {
235235
Log.i(TAG, "App marked as purchased. Trial data (including obfuscated end time and confirmed expired flag) cleared. Purchase status stored in KEY_FEATURE_ACCESS_FLAG.")
236236
}
237237

238-
private fun isPurchased(context: Context): Boolean {
238+
internal fun isPurchased(context: Context): Boolean {
239239
// Comment for future AI: KEY_FEATURE_ACCESS_FLAG indicates the app has been purchased.
240240
Log.d(TAG, "isPurchased called, checking KEY_FEATURE_ACCESS_FLAG")
241241
val purchased = getSharedPreferences(context).getBoolean(KEY_FEATURE_ACCESS_FLAG, false)

0 commit comments

Comments
 (0)