| @@ -15,9 +15,8 @@ | ||
| 15 | 15 | use Packetery\Module\Carrier\OptionPrefixer; |
| 16 | 16 | use Packetery\Module\Exception\ProductNotFoundException; |
| 17 | 17 | use Packetery\Module\FormFactory; |
| 18 | 18 | use Packetery\Module\Product; |
| 19 | -use Packetery\Module\WcLogger; | |
| 20 | 19 | use Packetery\Nette\Forms\Form; |
| 21 | 20 | |
| 22 | 21 | /** |
| 23 | 22 | * Class Tab |
| @@ -99,19 +98,13 @@ | ||
| 99 | 98 | |
| 100 | 99 | /** |
| 101 | 100 | * Registers tab. |
| 102 | 101 | * |
| 103 | - * @param string[]|mixed $tabs Tabs definition array. | |
| 102 | + * @param string[] $tabs Tabs definition array. | |
| 104 | 103 | * |
| 105 | - * @return array<array<string,string[]|string>|string>|mixed | |
| 104 | + * @return array<array<string,string[]|string>|string> | |
| 106 | 105 | */ |
| 107 | - public function registerTab( $tabs ) { | |
| 108 | - if ( ! is_array( $tabs ) ) { | |
| 109 | - WcLogger::logArgumentTypeError( __METHOD__, 'tabs', 'array', $tabs ); | |
| 110 | - | |
| 111 | - return $tabs; | |
| 112 | - } | |
| 113 | - | |
| 106 | + public function registerTab( array $tabs ): array { | |
| 114 | 107 | $tabs[ self::NAME ] = [ |
| 115 | 108 | 'label' => __( 'Packeta', 'packeta' ), |
| 116 | 109 | 'target' => self::NAME, |
| 117 | 110 | 'class' => [ 'hide_if_virtual', 'hide_if_downloadable' ], |