Removed unnecessary call to commitAllowingStateLoss