Skip to content

Conversation

@di72nn
Copy link
Member

@di72nn di72nn commented Jun 22, 2020

Test scenario: Main screen -> Add new entry -> OK.

Fixes the crash that's been reported in the "pre-launch report" and in the console:

06-20 10:23:54.413: E/AndroidRuntime(30523): FATAL EXCEPTION: Thread-2553
06-20 10:23:54.413: E/AndroidRuntime(30523): Process: fr.gaulupeau.apps.InThePoche, PID: 30523
06-20 10:23:54.413: E/AndroidRuntime(30523): android.util.AndroidRuntimeException: Calling startActivity() from outside of an Activity  context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want?
06-20 10:23:54.413: E/AndroidRuntime(30523): 	at android.app.ContextImpl.startActivity(ContextImpl.java:672)
06-20 10:23:54.413: E/AndroidRuntime(30523): 	at android.app.ContextImpl.startActivity(ContextImpl.java:659)
06-20 10:23:54.413: E/AndroidRuntime(30523): 	at fr.gaulupeau.apps.Poche.service.OperationsHelper.addArticleWithUI(OperationsHelper.java:39)
06-20 10:23:54.413: E/AndroidRuntime(30523): 	at fr.gaulupeau.apps.Poche.ui.MainActivity.lambda$showAddBagDialog$3$MainActivity(MainActivity.java:934)
06-20 10:23:54.413: E/AndroidRuntime(30523): 	at fr.gaulupeau.apps.Poche.ui.-$$Lambda$MainActivity$VI8v6PsPin0nTcg9cy19YmmIaEo.onClick(lambda)
06-20 10:23:54.413: E/AndroidRuntime(30523): 	at androidx.appcompat.app.AlertController$ButtonHandler.handleMessage(AlertController.java:167)
06-20 10:23:54.413: E/AndroidRuntime(30523): 	at android.os.Handler.dispatchMessage(Handler.java:102)

@tcitworld tcitworld merged commit 93aee15 into master Jun 22, 2020
@tcitworld tcitworld deleted the fix_add_dialog_crash branch June 22, 2020 09:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants