Skip to content

Commit

Permalink
php update
Browse files Browse the repository at this point in the history
  • Loading branch information
visavi committed Oct 25, 2019
1 parent d1656a2 commit aca9121
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
],
"require": {
"ext-json": "*",
"php": ">=7.2"
"php": ">=7.1"
},
"require-dev": {
"phpunit/phpunit": "8.3.5"
Expand Down
2 changes: 1 addition & 1 deletion src/Mapper/Map.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function containsObjectPath($objectPath)
*/
public function get($objectPath)
{
return isset($this->map[$objectPath]) ? $this->map[$objectPath] : null;
return $this->map[$objectPath] ?? null;
}

/**
Expand Down
4 changes: 2 additions & 2 deletions src/Mapper/MapFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public static function create(array $mapSchema)
foreach ($mapSchema as $key => $value) {
$tags = [];
if (strpos($key, ':') !== false) {
list($key, $tags) = explode(':', $key);
[$key, $tags] = explode(':', $key);
$tags = self::normaliseTags($tags);
}
$map->add(new MapItem($key, $value, $tags));
Expand Down Expand Up @@ -82,7 +82,7 @@ protected static function tagsFromString($tags)
if (strpos($tag, ' ') !== false) {
list($tag, $value) = explode(' ', $tag);
}
$result[$tag] = isset($value) ? $value : true;
$result[$tag] = $value ?? true;
}
return $result;
}
Expand Down

0 comments on commit aca9121

Please sign in to comment.