I have seen the code below and unable to figure it out.
if (mGoalProgressFragment != null) {
mCallerFramgent.getActivity().getSupportFragmentManager().beginTransaction().show(mGoalProgressFragment);
}
mCallerFramgent.getActivity().getSupportFragmentManager().beginTransaction().commit();
i am not able to understand the part when the if condition fails and commit()
is called.
and when if condition is true commit is not used for show transaction.
Can anyone help me understand this. because lint shows missing commit for the transaction inside the if selection.