Skip to content

Commit

Permalink
Merge pull request #1507 from Ultimater/fix-1506-cannot-create-contro…
Browse files Browse the repository at this point in the history
…llers

Fix #1506 config file locating issue
  • Loading branch information
Ultimater authored Jul 5, 2021
2 parents ffb6537 + fa16acc commit d31bc7c
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion scripts/Phalcon/Builder/AllModels.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function __construct(array $options = [])

public function build()
{
if ($this->options->offsetExists('directory')) {
if ($this->options->offsetExists('directory') && $this->options->get('directory') !== null) {
$this->path->setRootPath($this->options->get('directory'));
}

Expand Down
2 changes: 1 addition & 1 deletion scripts/Phalcon/Builder/Controller.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public function __construct(array $options = [])
*/
public function build()
{
if ($this->options->offsetExists('directory')) {
if ($this->options->offsetExists('directory') && $this->options->get('directory') !== null) {
$this->path->setRootPath($this->options->get('directory'));
}

Expand Down
2 changes: 1 addition & 1 deletion scripts/Phalcon/Builder/Module.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public function build()
. 'templates' . DIRECTORY_SEPARATOR . 'module';
}

if ($this->options->offsetExists('directory')) {
if ($this->options->offsetExists('directory') && $this->options->get('directory') !== null) {
$this->path->setRootPath($this->options->get('directory'));
}

Expand Down
2 changes: 1 addition & 1 deletion scripts/Phalcon/Builder/Project.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class Project extends Component
*/
public function build()
{
if ($this->options->offsetExists('directory')) {
if ($this->options->offsetExists('directory') && $this->options->get('directory') !== null) {
$this->path->setRootPath($this->options->get('directory'));
}

Expand Down

0 comments on commit d31bc7c

Please sign in to comment.