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

Returning Instead Of Breaking - Stop Processing Additional View Directories #14526

Merged
merged 4 commits into from
Nov 12, 2019

Conversation

Fenikkusu
Copy link
Contributor

@Fenikkusu Fenikkusu commented Nov 11, 2019

Hello!

In raising this pull request, I confirm the following:

  • I have read and understood the Contributing Guidelines
  • I have checked that another pull request for this purpose does not exist
  • I wrote some tests for this PR
  • I have updated the relevant CHANGELOG
  • I have created a PR for the documentation about this change

Small description of change:

If you specify multiple view directories using, it creates an abnormality where the same file will be included from every view directory it exists. Rather than continuing the view directory loop, this breaks out of the function completely.

Thanks

@niden
Copy link
Member

niden commented Nov 11, 2019

cc @maurits150 @memmaker - thanks to the original reporters of this.

@codecov
Copy link

codecov bot commented Nov 11, 2019

Codecov Report

Merging #14526 into 4.0.x will increase coverage by <.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##            4.0.x   #14526      +/-   ##
==========================================
+ Coverage   67.71%   67.71%   +<.01%     
==========================================
  Files         481      481              
  Lines      111827   111820       -7     
==========================================
- Hits        75719    75715       -4     
+ Misses      36108    36105       -3

@Fenikkusu
Copy link
Contributor Author

I'll get the testing added in tomorrow.

@maurits150
Copy link

I guess that notExists can be removed now that you always return when a view is found.

@Fenikkusu Fenikkusu force-pushed the 4.0.x-multiple-view-dirs branch from 4ec226f to 40605e5 Compare November 12, 2019 01:54
@Fenikkusu
Copy link
Contributor Author

I've added the testing in for this. Additionally, per @maurits150 , I have also removed the notExists boolean as it isn't needed anymore. I also went ahead and updated the change log.

@niden niden added 4.0 labels Nov 12, 2019
@niden niden merged commit 84e1bd5 into phalcon:4.0.x Nov 12, 2019
@niden
Copy link
Member

niden commented Nov 12, 2019

Excellent work. Thank you @Fenikkusu and @maurits150 for the implementation and input

@niden niden added bug A bug report status: low Low and removed Bug - Low labels Dec 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A bug report status: low Low
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants