diff --git a/app/src/main/java/org/gnucash/android/ui/transaction/SplitEditorFragment.java b/app/src/main/java/org/gnucash/android/ui/transaction/SplitEditorFragment.java index 841b32744..a8c7c9412 100644 --- a/app/src/main/java/org/gnucash/android/ui/transaction/SplitEditorFragment.java +++ b/app/src/main/java/org/gnucash/android/ui/transaction/SplitEditorFragment.java @@ -442,14 +442,23 @@ public void onClick(View view) { public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) { - // Change Transaction Type according to splitTypeSwitch - split.setType(splitTypeSwitch.getTransactionType()); + if (split != null) { + // Split not null - // Update Split Amount Signum - updateSplitAmountEditText(split); + // Change Transaction Type according to splitTypeSwitch + split.setType(splitTypeSwitch.getTransactionType()); - // Recompute Split List Balance - mImbalanceWatcher.afterTextChanged(null); + // Update Split Amount Signum + updateSplitAmountEditText(split); + + // Recompute Split List Balance + mImbalanceWatcher.afterTextChanged(null); + + } else { + // Split is null + + // RAF + } } }); }