Open
Conversation
This change moves all operations which deal with the fetching/updating, or setting of files from the file_storage class into a new file_system class. A new file_system can be specified in the config.php and used to replace all relevant methods in order to move the file system component to an alternative solution.
I noticed during the file system abstraction that this test was incorrect. Since both $storagefalse, and $storagetrue are in the same context, component, area, itemid, and folder, the fact that they had the same filename meant that they constantly overwrote one another. As part of archive_to_storage, existing files in the same location are found, the files themselves deleted, and the existing file record in the files table is deleted. The tests continued to pass because: * the existing variables were not affected by the deletion of the file record and file so the comparisons were successful; and * subsequent calls to fetch the content of the file meant that the files themselves were restored from the trash directory.
Also known as patch B
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
*** PLEASE DO NOT OPEN PULL REQUESTS VIA GITHUB ***
The moodle.git repository at Github is just a mirror of the official repository. We do not accept pull requests at Github.
See CONTRIBUTING.txt guidelines for how to contribute patches for Moodle. Thank you.
--