From 1870111fbacd62bbe571083eef5cdc05f313c617 Mon Sep 17 00:00:00 2001 From: Awilum Date: Mon, 26 Jul 2021 22:02:00 +0300 Subject: [PATCH] feat(actions): update Actions API and add AcationsHelper #549 --- src/flextype/Foundation/Actions.php | 8 ++++---- .../Foundation/Helpers/ActionsHelper.php | 20 +++++++++++++++++++ 2 files changed, 24 insertions(+), 4 deletions(-) create mode 100644 src/flextype/Foundation/Helpers/ActionsHelper.php diff --git a/src/flextype/Foundation/Actions.php b/src/flextype/Foundation/Actions.php index fb266901..48ff563a 100644 --- a/src/flextype/Foundation/Actions.php +++ b/src/flextype/Foundation/Actions.php @@ -22,9 +22,9 @@ class Actions extends Arrays private static ?Actions $instance = null; /** - * Actions storage + * Actions registry */ - private static ?Arrays $storage = null; + private static ?Arrays $registry = null; /** * Gets the instance via lazy initialization (created on first usage) @@ -35,8 +35,8 @@ class Actions extends Arrays static::$instance = new self(); } - if (static::$storage === null) { - static::$storage = new Arrays(); + if (static::$registry === null) { + static::$registry = new Arrays(); } return static::$instance; diff --git a/src/flextype/Foundation/Helpers/ActionsHelper.php b/src/flextype/Foundation/Helpers/ActionsHelper.php new file mode 100644 index 00000000..94ba31a4 --- /dev/null +++ b/src/flextype/Foundation/Helpers/ActionsHelper.php @@ -0,0 +1,20 @@ +