Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: showError in CLI/BaseCommand use hardcoded error view path #6657

Merged
merged 3 commits into from
Oct 10, 2022

Conversation

fpoy
Copy link
Contributor

@fpoy fpoy commented Oct 10, 2022

Fix #6656

Description

When you :

  • change the location of the views used to generate errors,
  • provide a new path in \Config\Exceptions::$errorViewPath,
  • and then run a CLI command generating an exception :

the error message is complaining about the location of the error_exception.php file... because the view path is hardcoded.

So instead of using a hardcoded directory for the error_exception.php file,

we should use the provided errorViewPath from \Config\Exceptions::$errorViewPath

Checklist:

  • Securely signed commits
  • Component(s) with PHPDoc blocks, only if necessary or adds value
  • Unit testing, with >80% coverage
  • User guide updated
  • Conforms to style guide

@MGatner
Copy link
Member

MGatner commented Oct 10, 2022

Nice catch! Please be sure to sign your commit - check the contributing guide for a step-by-step on how to apply that retroactively.

@kenjis kenjis added GPG-Signing needed Pull requests that need GPG-Signing bug Verified issues on the current code behavior or pull requests that will fix them labels Oct 10, 2022
@fpoy fpoy force-pushed the BUG_hardcoded_error_view_path branch from 052e434 to 3d02abc Compare October 10, 2022 10:54
@fpoy
Copy link
Contributor Author

fpoy commented Oct 10, 2022

OK, the commit is finally securely signed

@kenjis kenjis removed the GPG-Signing needed Pull requests that need GPG-Signing label Oct 10, 2022
@samsonasik samsonasik merged commit c7a47fa into codeigniter4:develop Oct 10, 2022
@samsonasik
Copy link
Member

Thank you @fpoy

@fpoy fpoy deleted the BUG_hardcoded_error_view_path branch October 11, 2022 09:19
@fpoy fpoy restored the BUG_hardcoded_error_view_path branch October 11, 2022 09:19
@fpoy fpoy deleted the BUG_hardcoded_error_view_path branch October 11, 2022 09:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Verified issues on the current code behavior or pull requests that will fix them
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: showError in CLI/BaseCommand use hardcoded error view path
4 participants