         } else {
             resultLabel.text = currentText.substring(to: currentText.characters.index(before: currentText.endIndex))
         }
+        
+        calculator.currentValue = Double(resultLabel!.text!)
     }
     
     @IBAction func onNegativeTapped(_ sender: CalculatorButton) {

    }
    
    @IBAction func onEqualsTapped(_ sender: CalculatorButton) {
        calculator.previousValue = calculator.currentValue
        calculator.currentValue = Double(resultLabel!.text!)
        
        guard let solution = calculator.solveEquation() else {
            return
        }

        } else {
            resultLabel.text?.append(period)
        }
        
        calculator.currentValue = Double(resultLabel!.text!)
    }
    
    @IBAction func onBackspaceTapped(_ sender: CalculatorButton) {
