@capgo/capacitor-stream-call 0.0.66 → 0.0.68
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.
|
@@ -154,16 +154,6 @@ public class StreamCallPlugin : Plugin() {
|
|
|
154
154
|
val serviceIntent = Intent(activity, StreamCallBackgroundService::class.java)
|
|
155
155
|
activity.startService(serviceIntent)
|
|
156
156
|
android.util.Log.d("StreamCallPlugin", "Started StreamCallBackgroundService to keep app alive")
|
|
157
|
-
|
|
158
|
-
// Handle initial intent if present
|
|
159
|
-
activity?.intent?.let { handleOnNewIntent(it) }
|
|
160
|
-
|
|
161
|
-
// process the very first intent that started the app (if any)
|
|
162
|
-
pendingIntent?.let {
|
|
163
|
-
android.util.Log.d("StreamCallPlugin","Processing saved initial intent")
|
|
164
|
-
handleOnNewIntent(it)
|
|
165
|
-
pendingIntent = null
|
|
166
|
-
}
|
|
167
157
|
}
|
|
168
158
|
|
|
169
159
|
@OptIn(DelicateCoroutinesApi::class)
|
|
@@ -240,6 +230,12 @@ public class StreamCallPlugin : Plugin() {
|
|
|
240
230
|
android.util.Log.d("StreamCallPlugin", "handleOnNewIntent: ACCEPT_CALL - Accepting call with cid: $cid")
|
|
241
231
|
val call = streamVideoClient?.call(id = cid.id, type = cid.type)
|
|
242
232
|
if (call != null) {
|
|
233
|
+
// Log the full stack trace to see exactly where this is called from
|
|
234
|
+
val stackTrace = Thread.currentThread().stackTrace
|
|
235
|
+
android.util.Log.d("StreamCallPlugin", "internalAcceptCall STACK TRACE:")
|
|
236
|
+
stackTrace.forEachIndexed { index, element ->
|
|
237
|
+
android.util.Log.d("StreamCallPlugin", " [$index] ${element.className}.${element.methodName}(${element.fileName}:${element.lineNumber})")
|
|
238
|
+
}
|
|
243
239
|
kotlinx.coroutines.GlobalScope.launch {
|
|
244
240
|
internalAcceptCall(call)
|
|
245
241
|
}
|
|
@@ -989,6 +985,7 @@ public class StreamCallPlugin : Plugin() {
|
|
|
989
985
|
@OptIn(DelicateCoroutinesApi::class, InternalStreamVideoApi::class)
|
|
990
986
|
internal fun internalAcceptCall(call: Call) {
|
|
991
987
|
android.util.Log.d("StreamCallPlugin", "internalAcceptCall: Entered for call: ${call.id}")
|
|
988
|
+
|
|
992
989
|
kotlinx.coroutines.GlobalScope.launch {
|
|
993
990
|
try {
|
|
994
991
|
android.util.Log.d("StreamCallPlugin", "internalAcceptCall: Coroutine started for call ${call.id}")
|
|
@@ -1851,18 +1848,12 @@ public class StreamCallPlugin : Plugin() {
|
|
|
1851
1848
|
}
|
|
1852
1849
|
|
|
1853
1850
|
companion object {
|
|
1854
|
-
private var pendingIntent: Intent? = null
|
|
1855
|
-
@JvmStatic fun saveInitialIntent(it: Intent) {
|
|
1856
|
-
pendingIntent = it
|
|
1857
|
-
}
|
|
1858
1851
|
@JvmStatic fun preLoadInit(ctx: Context, app: Application) {
|
|
1859
1852
|
holder ?: run {
|
|
1860
1853
|
val p = StreamCallPlugin()
|
|
1861
1854
|
p.savedContext = ctx
|
|
1862
1855
|
p.initializeStreamVideo(ctx, app)
|
|
1863
1856
|
holder = p
|
|
1864
|
-
// record the intent that started the process
|
|
1865
|
-
if (ctx is Activity) saveInitialIntent((ctx as Activity).intent)
|
|
1866
1857
|
}
|
|
1867
1858
|
}
|
|
1868
1859
|
private var holder: StreamCallPlugin? = null
|
package/package.json
CHANGED