]> git.mxchange.org Git - core.git/commitdiff
Continued:
authorRoland Häder <roland@mxchange.org>
Sun, 6 Dec 2020 23:58:00 +0000 (00:58 +0100)
committerRoland Häder <roland@mxchange.org>
Sun, 6 Dec 2020 23:58:00 +0000 (00:58 +0100)
- replaced old array() with "new" [] style

Signed-off-by: Roland Häder <roland@mxchange.org>
framework/main/classes/stacker/class_BaseStacker.php
framework/main/classes/stacker/file/class_BaseFileStack.php

index 70c6a229bf7c51c512138a6e9d9d89ce87db4ef6..9d857e75934f9322f4422bd82e4cc83be0f68aab 100644 (file)
@@ -228,7 +228,7 @@ abstract class BaseStacker extends BaseFrameworkSystem {
                        throw new BadMethodCallException(sprintf('stackerName=%s not yet initialized but method called.', $stackerName), self::EXCEPTION_NO_STACKER_FOUND);
                } elseif ($this->isStackFull($stackerName)) {
                        // Stacker is full
-                       throw new FullStackerException(array($this, $stackerName, $value), self::EXCEPTION_STACKER_IS_FULL);
+                       throw new FullStackerException([$this, $stackerName, $value], self::EXCEPTION_STACKER_IS_FULL);
                }
 
                // Now add the value to the stack
index 30f20f9c93fcc9c39e8564bfc6844155d979e65c..8abdaa669d89f5237192f052c4aef5ffd2d1f249 100644 (file)
@@ -279,7 +279,7 @@ abstract class BaseFileStack extends BaseStacker implements StackableFile {
                        throw new InvalidArgumentException('Parameter "stackerName" is empty');
                } elseif ($this->isStackFull($stackerName)) {
                        // Stacker is full
-                       throw new FullStackerException(array($this, $stackerName, $value), self::EXCEPTION_STACKER_IS_FULL);
+                       throw new FullStackerException([$this, $stackerName, $value], self::EXCEPTION_STACKER_IS_FULL);
                } elseif (is_resource($value) || is_object($value)) {
                        // Not wanted type
                        throw new InvalidArgumentException(sprintf('value[]=%s is not supported', gettype($value)));
@@ -314,7 +314,7 @@ abstract class BaseFileStack extends BaseStacker implements StackableFile {
                        throw new InvalidArgumentException('Parameter "stackerName" is empty');
                } elseif ($this->isStackEmpty($stackerName)) {
                        // Throw an exception
-                       throw new BadMethodCallException(array($this, $stackerName), self::EXCEPTION_STACKER_IS_EMPTY);
+                       throw new BadMethodCallException([$this, $stackerName], self::EXCEPTION_STACKER_IS_EMPTY);
                }
 
                // Now get the last value
@@ -342,7 +342,7 @@ abstract class BaseFileStack extends BaseStacker implements StackableFile {
                        throw new InvalidArgumentException('Parameter "stackerName" is empty');
                } elseif ($this->isStackEmpty($stackerName)) {
                        // Throw an exception
-                       throw new BadMethodCallException(array($this, $stackerName), self::EXCEPTION_STACKER_IS_EMPTY);
+                       throw new BadMethodCallException([$this, $stackerName], self::EXCEPTION_STACKER_IS_EMPTY);
                }
 
                // Now get the first value
@@ -370,7 +370,7 @@ abstract class BaseFileStack extends BaseStacker implements StackableFile {
                        throw new InvalidArgumentException('Parameter "stackerName" is empty');
                } elseif ($this->isStackEmpty($stackerName)) {
                        // Throw an exception
-                       throw new BadMethodCallException(array($this, $stackerName), self::EXCEPTION_STACKER_IS_EMPTY);
+                       throw new BadMethodCallException([$this, $stackerName], self::EXCEPTION_STACKER_IS_EMPTY);
                }
 
                // Now, remove the last entry, we don't care about the return value here, see elseif() block above
@@ -394,7 +394,7 @@ abstract class BaseFileStack extends BaseStacker implements StackableFile {
                        throw new InvalidArgumentException('Parameter "stackerName" is empty');
                } elseif ($this->isStackEmpty($stackerName)) {
                        // Throw an exception
-                       throw new BadMethodCallException(array($this, $stackerName), self::EXCEPTION_STACKER_IS_EMPTY);
+                       throw new BadMethodCallException([$this, $stackerName], self::EXCEPTION_STACKER_IS_EMPTY);
                }
 
                // Now, remove the last entry, we don't care about the return value here, see elseif() block above