From 90a0fa2dc73ffce64827981f9773a77a7261fea3 Mon Sep 17 00:00:00 2001 From: Danila Fedorin Date: Sat, 5 Aug 2017 14:43:24 -0700 Subject: [PATCH] Set output string correctly. --- src/main/java/org/nwapw/abacus/fx/AbacusController.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/nwapw/abacus/fx/AbacusController.java b/src/main/java/org/nwapw/abacus/fx/AbacusController.java index a3ebe22..5eb0275 100644 --- a/src/main/java/org/nwapw/abacus/fx/AbacusController.java +++ b/src/main/java/org/nwapw/abacus/fx/AbacusController.java @@ -127,11 +127,12 @@ public class AbacusController implements PluginListener { if (evaluatedNumber == null) { return ERR_EVAL; } - historyData.add(new HistoryModel(inputField.getText(), constructedTree.toString(), evaluatedNumber.toString())); + String resultingString = evaluatedNumber.toString(); + historyData.add(new HistoryModel(inputField.getText(), constructedTree.toString(), resultingString)); + return resultingString; } catch (ComputationInterruptedException exception) { return ERR_STOP; } - return ""; } @Override