title: onActivityResult() fragment transaction error
body: <p>I am trying to replace <code>fragment</code> in <code>onActivityResult()</code> but it always gives me error of <code>java.lang.illegalStateException.</code></p>
  
  <pre><code>Caused by: java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState
  12-29 18:50:21.455 5554-5554/com.package E/AndroidRuntime:     at android.support.v4.app.FragmentManagerImpl.checkStateLoss(FragmentManager.java:1377)
  12-29 18:50:21.455 5554-5554/com.package E/AndroidRuntime:     at     android.support.v4.app.FragmentManagerImpl.enqueueAction(FragmentManager.java:1395)
  12-29 18:50:21.455 5554-5554/com.package E/AndroidRuntime:     at android.support.v4.app.BackStackRecord.commitInternal(BackStackRecord.java:637)
  12-29 18:50:21.455 5554-5554/com.package E/AndroidRuntime:     at android.support.v4.app.BackStackRecord.commit(BackStackRecord.java:616)
  12-29 18:50:21.455 5554-5554/com.package E/AndroidRuntime:     at .virtualClass.VirtualPurchaseFragment.dealWithSuccessfulPurchase(VirtualPurchaseFragment.java:161)
  </code></pre>
  
  <p>Here is my <code>onActivityResult</code> code</p>
  
  <pre><code>@Override
  public void onActivityResult(int requestCode, int resultCode, Intent data) {
  
      Fragment fragment = new VirtualListFragment();
      FragmentManager fragmentManager = getFragmentManager();
      fragmentManager.beginTransaction().replace(R.id.frame_container, fragment).commit();
  
  }
  </code></pre>