Skip to content

Commit

Permalink
#11749 Changing the way the filename is read
Browse files Browse the repository at this point in the history
  • Loading branch information
burzum authored and saeideng committed Mar 22, 2018
1 parent a6e1fad commit 1804a44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Filesystem/File.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public function __construct($path, $create = false, $mode = 0755)
$splInfo = new SplFileInfo($path);
$this->Folder = new Folder($splInfo->getPath(), $create, $mode);
if (!is_dir($path)) {
$this->name = $splInfo->getBasename();
$this->name = ltrim($splInfo->getFilename(), '/');
}
$this->pwd();
$create && !$this->exists() && $this->safe($path) && $this->create();
Expand Down

0 comments on commit 1804a44

Please sign in to comment.