Skip to content

Commit 3fb19be

Browse files
committed
fix(Application): getNativeApplication wrong ActivityThread
fixes #10325
1 parent ed0989d commit 3fb19be

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/core/application/application.android.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ export class AndroidApplication extends ApplicationCommon implements IAndroidApp
323323
// the getInstance might return null if com.tns.NativeScriptApplication exists but is not the starting app type
324324
if (!nativeApp) {
325325
// TODO: Should we handle the case when a custom application type is provided and the user has not explicitly initialized the application module?
326-
const clazz = java.lang.Class.forName('androidx.appcompat.app.AppCompatActivityThread');
326+
const clazz = java.lang.Class.forName('android.app.ActivityThread');
327327
if (clazz) {
328328
const method = clazz.getMethod('currentApplication', null);
329329
if (method) {

0 commit comments

Comments
 (0)