Skip to content

Commit

Permalink
Merge pull request Studio-42#1002 from therevmj/2.x
Browse files Browse the repository at this point in the history
Fix edge case when the root is / and no alias is provided.
  • Loading branch information
nao-pon committed Mar 28, 2015
2 parents 68dcaf7 + 8702879 commit c611182
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions php/elFinderVolumeDriver.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -721,6 +721,11 @@ public function mount(array $opts) {
}

$this->rootName = empty($this->options['alias']) ? $this->_basename($this->root) : $this->options['alias'];

// This get's triggered if $this->root == '/' and alias is empty.
// Maybe modify _basename instead?
if (empty($this->rootName)) $this->rootName = $this->separator;

$root = $this->stat($this->root);

if (!$root) {
Expand Down

0 comments on commit c611182

Please sign in to comment.