@takeoffmedia/react-native-penthera 0.8.1 → 0.8.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/android/src/main/java/com/takeoffmediareactnativepenthera/virtuoso/OfflineVideoEngine.kt
CHANGED
|
@@ -215,17 +215,19 @@ class OfflineVideoEngine(private val context: ReactApplicationContext) {
|
|
|
215
215
|
if (columnName == "eap") {
|
|
216
216
|
eap = value
|
|
217
217
|
}
|
|
218
|
-
if (columnName == "creationTime") {
|
|
219
|
-
creationTime = value
|
|
220
|
-
}
|
|
221
218
|
if (columnName == "activePercentOfDownloads") {
|
|
222
219
|
val percentage = value.toDouble() * 100
|
|
223
220
|
val isComplete = percentage == 100.0
|
|
224
221
|
dataMap["isCompleted"] = isComplete
|
|
225
222
|
}
|
|
223
|
+
if (columnName == "creationTime") {
|
|
224
|
+
creationTime = value
|
|
225
|
+
}
|
|
226
226
|
if (columnName == "firstPlayTime") {
|
|
227
|
+
if(value != "0") {
|
|
228
|
+
creationTime = value
|
|
229
|
+
}
|
|
227
230
|
(dataMap["data"] as? MutableMap<String, Any> ?: mutableMapOf()).apply {
|
|
228
|
-
put("creationTime", if (value == "0") creationTime else value)
|
|
229
231
|
put("effectiveExpiryDate", if (value == "0") ead else eap);
|
|
230
232
|
put("isReproduced", value != "0");
|
|
231
233
|
}.also { dataMap["data"] = it }
|
|
@@ -233,6 +235,7 @@ class OfflineVideoEngine(private val context: ReactApplicationContext) {
|
|
|
233
235
|
}
|
|
234
236
|
}
|
|
235
237
|
dataMap["isPaused"] = false
|
|
238
|
+
dataMap["creationTime"] = creationTime
|
|
236
239
|
completedList.add(dataMap)
|
|
237
240
|
}
|
|
238
241
|
cursor.close()
|
package/ios/Penthera.swift
CHANGED
|
@@ -102,7 +102,7 @@ class Penthera: RCTEventEmitter, VirtuosoDownloadEngineNotificationsDelegate {
|
|
|
102
102
|
func initializeSdk(user: String, backplaneUrl: String, publicKey: String, privateKey: String, resolve: @escaping RCTPromiseResolveBlock, reject: @escaping RCTPromiseRejectBlock) -> Void {
|
|
103
103
|
guard let engineConfig = VirtuosoEngineConfig(
|
|
104
104
|
user: user,
|
|
105
|
-
backplaneUrl: backplaneUrl,
|
|
105
|
+
// backplaneUrl: backplaneUrl,
|
|
106
106
|
publicKey: publicKey,
|
|
107
107
|
privateKey: privateKey) else {
|
|
108
108
|
return reject("Penthera", "engine Config", nil)
|