This repository was archived by the owner on Jan 8, 2020. It is now read-only.
Make include_path functionality of Config and Translator opt-in#4767
Merged
Conversation
- Added `setUseIncludePath()` call to translator adapters - added flag, Factory::USE_INCLUDE_PATH, as second argument to config factory
- You must pass the `$useIncludePath` to either `fromFile()` or `fromFiles()` for it to be used. Constants were created with boolean values for those using IDEs.
- Created AbstractFileLoader, which provides implementation details for when/how to use the include_path to load translation file assets. - Updated INI, gettext, and PHP loaders to extend AbstractFileLoader.
- Added to translator loader plugin manager
Member
Author
|
This replaces #4766 |
- Remove constants, per @DASPRiD
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#4515 (which addresses #4443) and #4574 both introduce features that use PHP's
include_pathto identify application assets. While the functionality has reasonable use cases, as implemented, it introduces some performance impact, as the components look on theinclude_pathfor each and every file. Additionally, if.is not on theinclude_path, files that resolve from the current working directory will not resolve.