From f83c84ce4e01ed758cebe24a464b541522df20ec Mon Sep 17 00:00:00 2001 From: Samuel Holland Date: Thu, 24 Aug 2017 01:22:49 -0500 Subject: [PATCH] ConfigActivity: Avoid unnecessary executePendingTransactions Nothing later tries to find the list using findFragmentById(). Signed-off-by: Jason A. Donenfeld --- app/src/main/java/com/wireguard/android/ConfigActivity.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/src/main/java/com/wireguard/android/ConfigActivity.java b/app/src/main/java/com/wireguard/android/ConfigActivity.java index 9743720b..b572f7f6 100644 --- a/app/src/main/java/com/wireguard/android/ConfigActivity.java +++ b/app/src/main/java/com/wireguard/android/ConfigActivity.java @@ -106,10 +106,8 @@ public class ConfigActivity extends BaseConfigActivity { return; // Ensure the list is present in the master pane. It will be restored on activity restarts! final BaseConfigFragment listFragment = fragments.get(TAG_LIST); - if (fm.findFragmentById(R.id.master_fragment) == null) { + if (fm.findFragmentById(R.id.master_fragment) == null) fm.beginTransaction().add(R.id.master_fragment, listFragment, TAG_LIST).commit(); - fm.executePendingTransactions(); - } // In the single-pane layout, the main container starts holding the list fragment. if (!isSplitLayout && visibleFragmentTag == null) visibleFragmentTag = TAG_LIST;