Skip to content

Commit

Permalink
Merge pull request #281 from jeremykendall/bugfix/cache-default-initi…
Browse files Browse the repository at this point in the history
…alisation

#280 bug fix cache throws when default cache directory is not present
  • Loading branch information
nyamsprod authored Aug 5, 2020
2 parents 61f50ec + 4f2c86e commit 3253280
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 1 deletion.
19 changes: 19 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,24 @@

All Notable changes to `PHP Domain Parser` **5.x** series will be documented in this file

## 5.7.1 - 2020-08-04

### Added

- None

### Fixed

- Cache throws when cache directory doesn't exist [#280](https://github.com/jeremykendall/php-domain-parser/issues/280)

### Deprecated

- None

### Removed

- None

## 5.7.0 - 2020-08-02

### Added
Expand All @@ -15,6 +33,7 @@ All Notable changes to `PHP Domain Parser` **5.x** series will be documented in

- Improve type hinting and return type by dropping EOL PHP versions support.
- Improve development environment by dropping EOL PHP versions support.
- Composer script

### Deprecated

Expand Down
2 changes: 1 addition & 1 deletion src/Cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public function __construct(string $cache_path = '')
{
if ('' === $cache_path) {
/** @var string $cache_path */
$cache_path = realpath(dirname(__DIR__).DIRECTORY_SEPARATOR.'data');
$cache_path = realpath(dirname(__DIR__)).DIRECTORY_SEPARATOR.'data';
}

if (!file_exists($cache_path) && file_exists(dirname($cache_path))) {
Expand Down

0 comments on commit 3253280

Please sign in to comment.