Skip to content

Commit

Permalink
Fixed syntax (backward compatibility for PHP 5.6)
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-wdmg committed Jun 20, 2021
1 parent 786cf36 commit 210f89a
Show file tree
Hide file tree
Showing 13 changed files with 15 additions and 1,770 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
Changelog
=========

## 1.4.8 (2021-06-20)
* Fixed syntax (backward compatibility for PHP 5.6)

## 1.4.7 (2021-06-08)
* Added `StringHelper::formatBytes()` method

Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ To install the helpers, run the following command in the console:
`$ composer require "wdmg/yii2-helpers"`

# Status and version [ready to use]
* v.1.4.8 - Backward compatibility for PHP 5.6
* v.1.4.7 - Added `StringHelper::formatBytes()` method
* v.1.4.6 - Added `ExchangeRates` helper
* v.1.4.5 - Added methods for working with timezones `DateAndTime::getTimezones(...)`
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"keywords": ["yii", "yii2", "extension", "helper", "array-helper", "daterime-helper", "ip-helper", "string-helper", "text-analyzer", "utilities", "wdmg"],
"type": "yii2-extension",
"license": "MIT",
"version": "1.4.7",
"version": "1.4.8",
"homepage": "https://github.com/wdmg/yii2-helpers",
"support": {
"source": "https://github.com/wdmg/yii2-helpers",
Expand Down
4 changes: 2 additions & 2 deletions src/ArrayHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Yii2 Custom array helper
*
* @category Helpers
* @version 1.4.7
* @version 1.4.8
* @author Alexsander Vyshnyvetskyy <[email protected]>
* @link https://github.com/wdmg/yii2-helpers
* @copyright Copyright (c) 2019 - 2021 W.D.M.Group, Ukraine
Expand Down Expand Up @@ -390,7 +390,7 @@ public static function changeKey($array = [], $keySetOrCallBack = [])
if (is_callable($keySetOrCallBack))
$key = call_user_func_array($keySetOrCallBack, [$k, $v]);
else
$key = $keySetOrCallBack[$k] ?? $k;
$key = isset($keySetOrCallBack[$k]) ? $keySetOrCallBack[$k] : $k;

$output[$key] = is_array($v) ? self::changeKey($v, $keySetOrCallBack) : $v;
}
Expand Down
2 changes: 1 addition & 1 deletion src/DateAndTime.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Yii2 Date and Time helper
*
* @category Helpers
* @version 1.4.7
* @version 1.4.8
* @author Alexsander Vyshnyvetskyy <[email protected]>
* @link https://github.com/wdmg/yii2-helpers
* @copyright Copyright (c) 2019 - 2021 W.D.M.Group, Ukraine
Expand Down
2 changes: 1 addition & 1 deletion src/DbSchemaTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Yii2 Extend DB schema
*
* @category Helpers
* @version 1.4.7
* @version 1.4.8
* @author Alexsander Vyshnyvetskyy <[email protected]>
* @link https://github.com/wdmg/yii2-helpers
* @copyright Copyright (c) 2019 - 2021 W.D.M.Group, Ukraine
Expand Down
2 changes: 1 addition & 1 deletion src/ExchangeRates.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Yii2 Exchange Rates
*
* @category Helpers
* @version 1.4.7
* @version 1.4.8
* @author Alexsander Vyshnyvetskyy <[email protected]>
* @link https://github.com/wdmg/yii2-helpers
* @copyright Copyright (c) 2019 - 2021 W.D.M.Group, Ukraine
Expand Down
2 changes: 1 addition & 1 deletion src/FileHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Yii2 Custom file helper
*
* @category Helpers
* @version 1.4.7
* @version 1.4.8
* @author Alexsander Vyshnyvetskyy <[email protected]>
* @link https://github.com/wdmg/yii2-helpers
* @copyright Copyright (c) 2019 - 2021 W.D.M.Group, Ukraine
Expand Down
2 changes: 1 addition & 1 deletion src/IpAddressHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Yii2 IP address helper
*
* @category Helpers
* @version 1.4.7
* @version 1.4.8
* @author Alexsander Vyshnyvetskyy <[email protected]>, Jonavon Wilcox <[email protected]>, Manuel Kasper <[email protected]>
* @see https://gist.github.com/stibiumz/5e6a92a195c50c875649, https://gist.github.com/jonavon/2028872, http://m0n0.ch/wall, https://www.experts-exchange.com/questions/23903322/Need-PHP-code-for-calculating-subnets.html
* @link https://github.com/wdmg/yii2-helpers
Expand Down
Loading

0 comments on commit 210f89a

Please sign in to comment.