Skip to content

Commit

Permalink
Cover FileHelper methods with BC promise
Browse files Browse the repository at this point in the history
  • Loading branch information
ondrejmirtes committed Jul 15, 2021
1 parent 39bd937 commit 4f9488e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/File/FileHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public function getWorkingDirectory(): string
return $this->workingDirectory;
}

/** @api */
public function absolutizePath(string $path): string
{
if (DIRECTORY_SEPARATOR === '/') {
Expand All @@ -37,6 +38,7 @@ public function absolutizePath(string $path): string
return rtrim($this->getWorkingDirectory(), '/\\') . DIRECTORY_SEPARATOR . ltrim($path, '/\\');
}

/** @api */
public function normalizePath(string $originalPath, string $directorySeparator = DIRECTORY_SEPARATOR): string
{
$matches = \Nette\Utils\Strings::match($originalPath, '~^([a-z]+)\\:\\/\\/(.+)~');
Expand Down

0 comments on commit 4f9488e

Please sign in to comment.