Skip to content

Commit

Permalink
Merge pull request #238 from Genti2024/feat/pgreq-two
Browse files Browse the repository at this point in the history
Fix: #207 인앱결제 관련 의존성 버전 수정(build.gradle)
  • Loading branch information
LeeJae-H authored Dec 5, 2024
2 parents cc2895e + 2327eaa commit 3568949
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
12 changes: 10 additions & 2 deletions genti-api/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,17 @@ dependencies {
// redis
implementation 'org.springframework.boot:spring-boot-starter-data-redis'

implementation "com.google.api-client:google-api-client:1.33.0"
// implementation "com.google.api-client:google-api-client:1.33.0"
// implementation 'com.google.auth:google-auth-library-oauth2-http:1.6.0'
//// implementation 'com.google.apis:google-api-services-androidpublisher:v2-rev22-1.21.0'
// compileOnly('com.google.apis:google-api-services-androidpublisher:v3-rev20241016-2.0.0')
compileOnly "com.google.api-client:google-api-client:2.2.0"
implementation "com.google.api-client:google-api-client:2.2.0"
implementation 'com.google.auth:google-auth-library-oauth2-http:1.6.0'
implementation 'com.google.apis:google-api-services-androidpublisher:v2-rev22-1.21.0'
// compileOnly 'com.google.apis:google-api-services-androidpublisher:v3-rev20220411-1.32.1'
implementation 'com.google.apis:google-api-services-androidpublisher:v3-rev20241016-2.0.0'
implementation group: 'com.google.http-client', name: 'google-http-client-jackson2', version: '1.41.7'


// test && test h2
testImplementation 'org.springframework.boot:spring-boot-starter-test'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public Boolean validateReceipt(Long userId, PurchaseRequestDto purchaseRequestDt
}

try {
ProductPurchase productPurchase = get.execute();
ProductPurchase productPurchase = get.execute(); // Google Cloud Platform에서 Android Publisher API 사용하기 눌러야 함.

// 구매 상태 -> 0 : 구매완료 / 1 : 취소됨
Integer purchaseState = productPurchase.getPurchaseState();
Expand All @@ -78,7 +78,7 @@ public Boolean validateReceipt(Long userId, PurchaseRequestDto purchaseRequestDt
return true;

} catch (IOException e5) {
throw ExpectedException.withLogging(ResponseCode.FileTypeNotProvided, e5);
throw new RuntimeException(e5);
}
}
}

0 comments on commit 3568949

Please sign in to comment.