Skip to content

Commit

Permalink
Merge pull request #3 from geekwright/newdirstructure
Browse files Browse the repository at this point in the history
Fix directories
  • Loading branch information
geekwright authored Feb 20, 2019
2 parents 9fc6cb7 + deccaaa commit 2e465b4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ The `composer.json` of the main xoops-library package needs to set the filesyste

```JSON
"extra": {
"xoops_modules": "/home/user/htdocs/modules/"
"xoops_modules": "/home/user/htdocs/modules"
}
```

Expand Down
4 changes: 2 additions & 2 deletions src/ModuleInstaller.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,14 @@ public function getInstallPath(PackageInterface $package)
{
$moddir = explode('/', $package->getName());

$xoops_modules = '../modules/';
$xoops_modules = './htdocs/modules';

$extra = $this->composer->getPackage()->getExtra();
if (isset($extra['xoops_modules_path'])) {
$xoops_modules = $extra['xoops_modules_path'];
}

return $xoops_modules . $moddir[1];
return $xoops_modules . '/' . $moddir[1];
}

/**
Expand Down

0 comments on commit 2e465b4

Please sign in to comment.