parent
							
								
									093e309e52
								
							
						
					
					
						commit
						9d7fd12cf3
					
				|  | @ -184,12 +184,6 @@ namespace Guru | |||
|                 success = false; | ||||
|             } | ||||
|             Callbacks.SDK._onUserAuthResult?.Invoke(success); | ||||
| 
 | ||||
|             if (success && !IsIAPReady) | ||||
|             { | ||||
|                 StartIapService(); | ||||
|             } | ||||
| 
 | ||||
|         } | ||||
|          | ||||
|         private void OnFirebaseAuthResult(bool success) | ||||
|  | @ -350,7 +344,24 @@ namespace Guru | |||
|                  | ||||
|             } | ||||
|             //----------- Set IAP ---------------- | ||||
|             if (useIAP) | ||||
|             { | ||||
|                 // InitIAP(_initConfig.GoogleKeys, _initConfig.AppleRootCerts); // 初始化IAP | ||||
|                 Try(() => | ||||
|                 { | ||||
|                     LogI($"#4.3 --- Start IAP ---"); | ||||
|                     if (_initConfig.GoogleKeys == null || _initConfig.AppleRootCerts == null) | ||||
|                     { | ||||
|                         LogException("[IAP] GoogleKeys is null when using IAPService! Integration failed. App will Exit"); | ||||
|                     } | ||||
| 
 | ||||
| 
 | ||||
|                     InitIAP(UID, _initConfig.GoogleKeys, _initConfig.AppleRootCerts); // 初始化IAP | ||||
|                 }, ex => | ||||
|                 { | ||||
|                     UnityEngine.Debug.LogError($"--- ERROR on useIAP: {ex.Message}"); | ||||
|                 }); | ||||
|             } | ||||
|             //----------- Set Keywords ---------------- | ||||
|             if (useKeywords) | ||||
|             { | ||||
|  | @ -406,37 +417,6 @@ namespace Guru | |||
| #endif | ||||
|         } | ||||
|          | ||||
| 
 | ||||
| 
 | ||||
|         private void StartIapService() | ||||
|         { | ||||
|             LogI($"#4.3 --- Start IAP ---"); | ||||
|             if (_initConfig.IAPEnabled && _appServicesConfig.IsIAPEnabled()) | ||||
|             { | ||||
|                 // InitIAP(_initConfig.GoogleKeys, _initConfig.AppleRootCerts); // 初始化IAP | ||||
|                 Try(() => | ||||
|                 { | ||||
|                     if (_initConfig.GoogleKeys == null || _initConfig.AppleRootCerts == null) | ||||
|                     { | ||||
|                         LogException("[IAP] GoogleKeys is null when using IAPService! Integration failed. App will Exit"); | ||||
|                         return; | ||||
|                     } | ||||
|                      | ||||
|                     InitIAP(UID, _initConfig.GoogleKeys, _initConfig.AppleRootCerts); // 初始化IAP | ||||
|                 }, ex => | ||||
|                 { | ||||
|                     UnityEngine.Debug.LogError($"--- ERROR on useIAP: {ex.Message}"); | ||||
|                 }); | ||||
|             } | ||||
|             else | ||||
|             { | ||||
|                 LogI($"--- IAP is not enabled, skip IAP service init ::    _initConfig.IAPEnabled:{_initConfig.IAPEnabled}     guruService.IsIAPEnabled:{_appServicesConfig.IsIAPEnabled()}"); | ||||
|             } | ||||
|              | ||||
|         } | ||||
| 
 | ||||
| 
 | ||||
| 
 | ||||
|         /// <summary> | ||||
|         /// Get the guru-service cloud config value; | ||||
|         /// User can fetch the cloud guru-service config by using Custom Service Key | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue