Skip to content

Commit

Permalink
Minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
xeriab committed Oct 11, 2016
1 parent 5c24e5e commit c105d3c
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 13 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#

test.php
tool.bat
tool.sh
composer.lock
composer.bak.json
Expand Down
10 changes: 5 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "xeriab/konfig",
"description": "Yet another simple configuration loader library.",
"homepage": "http://xeriab.github.io/projects/konfig/",
"version": "0.1.9",
"version": "0.2.0",
"license": "MIT",
"type": "library",
"keywords": [
Expand Down Expand Up @@ -33,9 +33,9 @@
"source": "https://github.com/xeriab/konfig"
},
"suggest": {
"yosymfony/toml": "Required to use and support TOML",
"symfony/yaml": "Required to use and support YAML",
"nette/neon": "Required to use and support the NEON notation"
"yosymfony/toml": "~0.3.3",
"symfony/yaml": "~2.8.12",
"nette/neon": "~2.3.5"
},
"require": {
"php": ">=5.4.0"
Expand All @@ -44,7 +44,7 @@
"yosymfony/toml": "~0.3.3",
"symfony/yaml": "~2.8.12",
"nette/neon": "~2.3.5",
"phpunit/phpunit": "~4.8.27",
"phpunit/phpunit": ">=4.8 < 6.0",
"scrutinizer/ocular": "~1.3.1",
"squizlabs/php_codesniffer": "~3.0.0RC1"
},
Expand Down
12 changes: 6 additions & 6 deletions src/Arr.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ final class Arr
* @codeCoverageIgnore
* @since 0.1.0
*/
public static function get(array $array, $key, string $default = null)
public static function get(array $array, $key, $default = null)
{
if (!is_array($array) && !$array instanceof \ArrayAccess) {
throw new \InvalidArgumentException('First parameter must be an array or ArrayAccess object.');
Expand Down Expand Up @@ -70,7 +70,7 @@ public static function get(array $array, $key, string $default = null)
* @codeCoverageIgnore
* @since 0.1.0
*/
public static function set(array &$array, $key, string $value = null)
public static function set(array &$array, $key, $value = null)
{
if (is_null($key)) {
$array = $value;
Expand Down Expand Up @@ -187,7 +187,7 @@ public static function mergeAssoc()
* @codeCoverageIgnore
* @since 0.1.0
*/
public static function delete(array &$array, string $key)
public static function delete(array &$array, $key)
{
if (is_null($key)) {
return false;
Expand Down Expand Up @@ -232,7 +232,7 @@ public static function delete(array &$array, string $key)
* @codeCoverageIgnore
* @since 0.1.0
*/
public static function keys(array $array, int $maxDepth = INF, int $depth = 0, array $arraykeys = [])
public static function keys(array $array, $maxDepth = INF, $depth = 0, array $arraykeys = [])
{
if ($depth < $maxDepth) {
$depth++;
Expand All @@ -252,12 +252,12 @@ public static function keys(array $array, int $maxDepth = INF, int $depth = 0, a
* Get array keys recursively
*
* @param array $array The search array
* @param type $search The search value
* @param string $search The search value
* @return array
* @codeCoverageIgnore
* @since 0.1.2
*/
public static function recursiveKeys(array $array, string $search = null)
public static function recursiveKeys(array $array, $search = null)
{
$return = (
$search !== null ?
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/ParseException.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function __construct(array $error)
$lineNo = isset($error['line']) ? $error['line'] : __LINE__;
$exception = isset($error['exception']) ? $error['exception'] : null;
$snippet = isset($error['snippet']) ? $error['snippet'] : null;
$previous = isset($error['previous']) ? $error['previous'] : null;
// $previous = isset($error['previous']) ? $error['previous'] : null;

$this->parsedFile = $fileName;
$this->parsedLine = $lineNo;
Expand Down

0 comments on commit c105d3c

Please sign in to comment.