InKwon James Kim
5 years ago
7 changed files with 72 additions and 10 deletions
-
8GME Remit.xcodeproj/project.pbxproj
-
1GME Remit/AppDelegate.swift
-
8GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyReceipt/User Interface/View/SendMoneyReceiptViewController.swift
-
18GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift
-
1GME Remit/Utilities/Database/GMEDB.swift
-
36GME Remit/Utilities/StoreReviewHelper.swift
-
4fastlane/Fastfile
@ -0,0 +1,36 @@ |
|||
// |
|||
// StoreReviewHelper.swift |
|||
// GME Remit |
|||
// |
|||
// Created by InKwon James Kim on 02/10/2019. |
|||
// Copyright © 2019 Gobal Money Express Co. Ltd. All rights reserved. |
|||
// |
|||
|
|||
import Foundation |
|||
import StoreKit |
|||
|
|||
class StoreReviewHelper { |
|||
static let shared = StoreReviewHelper() |
|||
|
|||
func incrementAppOpenedCount() { |
|||
var appOpenCount = GMEDB.shared.app.integer(.openCount) |
|||
|
|||
appOpenCount += 1 |
|||
GMEDB.shared.app.set(appOpenCount, .openCount) |
|||
} |
|||
|
|||
func checkAndAskForReview() { |
|||
requestReview() |
|||
// let openCount = GMEDB.shared.app.integer(.openCount) |
|||
// |
|||
// switch openCount { |
|||
// case 3, 5: StoreReviewHelper().requestReview() |
|||
// case _ where openCount % 100 == 0 : StoreReviewHelper().requestReview() |
|||
// default: print("App run count is : \(openCount)") |
|||
// } |
|||
} |
|||
|
|||
private func requestReview() { |
|||
SKStoreReviewController.requestReview() |
|||
} |
|||
} |
Write
Preview
Loading…
Cancel
Save
Reference in new issue