From ea898d7a7b85aeb677f81f13784232c99b61808a Mon Sep 17 00:00:00 2001 From: Alexander Kiryukhin Date: Mon, 1 Jun 2020 03:50:39 +0300 Subject: Code style fixes & Github Actions (#65) * Code style fixes Up phpunit to v8 New CI * Remove travis * Fix CI badge * Added php-cs-fixer action --- src/NXP/MathExecutor.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/NXP/MathExecutor.php') diff --git a/src/NXP/MathExecutor.php b/src/NXP/MathExecutor.php index 9a45589..8f876dc 100644 --- a/src/NXP/MathExecutor.php +++ b/src/NXP/MathExecutor.php @@ -15,8 +15,9 @@ use NXP\Classes\Calculator; use NXP\Classes\CustomFunction; use NXP\Classes\Operator; use NXP\Classes\Tokenizer; -use NXP\MathExecutorException; +use NXP\Exception\MathExecutorException; use NXP\Exception\DivisionByZeroException; +use NXP\Exception\UnknownVariableException; use ReflectionException; /** @@ -403,7 +404,7 @@ class MathExecutor public function getVar(string $variable) { if (!isset($this->variables[$variable])) { - throw new UnknownVariableException("Variable ({$variable}) not set"); + throw new UnknownVariableException("Variable ({$variable}) not set"); } return $this->variables[$variable]; } @@ -444,7 +445,7 @@ class MathExecutor return $this; } - /** + /** * Remove variable from executor * * @param string $variable @@ -452,7 +453,7 @@ class MathExecutor */ public function removeVar(string $variable) : self { - unset ($this->variables[$variable]); + unset($this->variables[$variable]); return $this; } -- cgit v1.2.3