@layers/react-native 0.2.0-alpha.1 → 0.2.0-alpha.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ios/LayersSKAN.swift +3 -1
- package/package.json +1 -1
package/ios/LayersSKAN.swift
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import Foundation
|
|
2
2
|
import StoreKit
|
|
3
|
+
import React
|
|
3
4
|
|
|
4
5
|
@objc(LayersSKAN)
|
|
5
6
|
class LayersSKAN: NSObject {
|
|
@@ -150,8 +151,9 @@ class LayersSKAN: NSObject {
|
|
|
150
151
|
}
|
|
151
152
|
|
|
152
153
|
let lock = lockWindow?.boolValue ?? false
|
|
154
|
+
let coarseValueOrDefault = coarse ?? .low // Default to .low if not specified
|
|
153
155
|
|
|
154
|
-
SKAdNetwork.updatePostbackConversionValue(intValue, coarseValue:
|
|
156
|
+
SKAdNetwork.updatePostbackConversionValue(intValue, coarseValue: coarseValueOrDefault, lockWindow: lock) { error in
|
|
155
157
|
if let error = error {
|
|
156
158
|
print("[Layers SKAN] Error updating postback: \(error.localizedDescription)")
|
|
157
159
|
reject("UPDATE_FAILED", error.localizedDescription, error)
|