From ddd6b9adaf87b89fd1a406659154b1382054a806 Mon Sep 17 00:00:00 2001 From: Dennis Eichhorn Date: Thu, 15 Aug 2019 21:55:12 +0200 Subject: [PATCH] Implement php 7.4 type hints --- Controller/Controller.php | 4 ++-- Models/TagMapper.php | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Controller/Controller.php b/Controller/Controller.php index 6f294c1..b4d2a28 100644 --- a/Controller/Controller.php +++ b/Controller/Controller.php @@ -66,7 +66,7 @@ class Controller extends ModuleAbstract implements WebInterface * @var string[] * @since 1.0.0 */ - protected static $providing = []; + protected static array $providing = []; /** * Dependencies. @@ -74,5 +74,5 @@ class Controller extends ModuleAbstract implements WebInterface * @var string[] * @since 1.0.0 */ - protected static $dependencies = []; + protected static array $dependencies = []; } diff --git a/Models/TagMapper.php b/Models/TagMapper.php index c065a71..4e584d2 100644 --- a/Models/TagMapper.php +++ b/Models/TagMapper.php @@ -33,7 +33,7 @@ final class TagMapper extends DataMapperAbstract * @var array> * @since 1.0.0 */ - protected static $columns = [ + protected static array $columns = [ 'tag_id' => ['name' => 'tag_id', 'type' => 'int', 'internal' => 'id'], 'tag_title' => ['name' => 'tag_title', 'type' => 'string', 'internal' => 'title'], 'tag_color' => ['name' => 'tag_color', 'type' => 'string', 'internal' => 'color'], @@ -48,7 +48,7 @@ final class TagMapper extends DataMapperAbstract * @var array> * @since 1.0.0 */ - protected static $belongsTo = [ + protected static array $belongsTo = [ 'createdBy' => [ 'mapper' => AccountMapper::class, 'src' => 'tag_created_by', @@ -61,7 +61,7 @@ final class TagMapper extends DataMapperAbstract * @var string * @since 1.0.0 */ - protected static $table = 'tag'; + protected static string $table = 'tag'; /** * Primary field name. @@ -69,5 +69,5 @@ final class TagMapper extends DataMapperAbstract * @var string * @since 1.0.0 */ - protected static $primaryField = 'tag_id'; + protected static string $primaryField = 'tag_id'; }