diff --git a/src/Controller/Component/RefererComponent.php b/src/Controller/Component/RefererComponent.php index 3828280..4bc6c02 100644 --- a/src/Controller/Component/RefererComponent.php +++ b/src/Controller/Component/RefererComponent.php @@ -34,7 +34,7 @@ class RefererComponent extends Component * * @var array */ - protected $_defaultConfig = [ + protected array $_defaultConfig = [ 'ignored' => [], ]; diff --git a/src/Model/Entity/File.php b/src/Model/Entity/File.php index 882e7c5..c112e5b 100644 --- a/src/Model/Entity/File.php +++ b/src/Model/Entity/File.php @@ -20,8 +20,8 @@ * @property string|false $contents * @property string $base64 * @property \Cake\ORM\Entity\text|array|null $meta - * @property \Cake\I18n\FrozenTime|null $created - * @property \Cake\I18n\FrozenTime|null $modified + * @property \Cake\I18n\DateTime|null $created + * @property \Cake\I18n\DateTime|null $modified */ class File extends Entity { @@ -33,7 +33,7 @@ class File extends Entity * * @var array */ - protected $_accessible = [ + protected array $_accessible = [ '*' => true, 'id' => false, 'Referer' => false, diff --git a/src/Model/Validation.php b/src/Model/Validation.php index aa979d7..a8b93b7 100644 --- a/src/Model/Validation.php +++ b/src/Model/Validation.php @@ -62,7 +62,7 @@ public static function ssn(string $check): bool */ public static function birthdate(Time $check): bool { - $today = new FrozenTime('00:00:00'); + $today = new \Cake\I18n\DateTime('00:00:00'); if ($check->toUnixString() > $today->toUnixString()) { return false; } diff --git a/src/Plugin.php b/src/Plugin.php index 126b8f7..6660b6d 100644 --- a/src/Plugin.php +++ b/src/Plugin.php @@ -24,7 +24,7 @@ class Plugin extends BasePlugin * * @var string */ - protected $name = 'ButterCream'; + protected ?string $name = 'ButterCream'; /** * Load all the plugin configuration and bootstrap logic. diff --git a/src/View/Helper/AjaxHelper.php b/src/View/Helper/AjaxHelper.php index 43348bc..d32683e 100644 --- a/src/View/Helper/AjaxHelper.php +++ b/src/View/Helper/AjaxHelper.php @@ -19,7 +19,7 @@ class AjaxHelper extends Helper * * @var array */ - protected $_defaultConfig = [ + protected array $_defaultConfig = [ 'templates' => [ 'tag' => '<{{tag}}{{attrs}}>{{content}}', ], diff --git a/src/View/Helper/GravatarHelper.php b/src/View/Helper/GravatarHelper.php index 73dafb7..7fef00f 100644 --- a/src/View/Helper/GravatarHelper.php +++ b/src/View/Helper/GravatarHelper.php @@ -17,7 +17,7 @@ class GravatarHelper extends Helper * * @var array */ - public $helpers = ['Html']; + public array $helpers = ['Html']; /** * Takes and email address and options and returns a gravatar diff --git a/src/View/Helper/NestedTreeHelper.php b/src/View/Helper/NestedTreeHelper.php index 37f3a27..22c27f3 100644 --- a/src/View/Helper/NestedTreeHelper.php +++ b/src/View/Helper/NestedTreeHelper.php @@ -18,14 +18,14 @@ class NestedTreeHelper extends Helper * * @var array */ - public $helpers = ['Html']; + public array $helpers = ['Html']; /** * Default config for this class * * @var array */ - protected $_defaultConfig = [ + protected array $_defaultConfig = [ 'templates' => [ 'container' => '{{content}}', 'list' => '{{content}}', diff --git a/src/View/Helper/TableHelper.php b/src/View/Helper/TableHelper.php index 4f3880c..9ea242d 100644 --- a/src/View/Helper/TableHelper.php +++ b/src/View/Helper/TableHelper.php @@ -24,14 +24,14 @@ class TableHelper extends Helper * * @var array */ - public $helpers = ['Html', 'Paginator']; + public array $helpers = ['Html', 'Paginator']; /** * Default config for this class * * @var array */ - protected $_defaultConfig = [ + protected array $_defaultConfig = [ 'templates' => [ 'tableheader' => '{{content}}{{help}}', ], diff --git a/src/View/Helper/TimeHelper.php b/src/View/Helper/TimeHelper.php index e03e441..69d01c4 100644 --- a/src/View/Helper/TimeHelper.php +++ b/src/View/Helper/TimeHelper.php @@ -35,7 +35,7 @@ public function userFormat($date, ?string $format = null, $invalid = false, $tim } try { if ($date instanceof DateTimeInterface) { - $date = new FrozenTime($date); + $date = new \Cake\I18n\DateTime($date); } $date->timezone = $timezone;