Skip to content
Snippets Groups Projects
Commit 5fa571a9 authored by Erik Johnston's avatar Erik Johnston
Browse files

Tell storage providers about new file so they can upload

parent 617199d7
No related branches found
No related tags found
No related merge requests found
......@@ -70,6 +70,12 @@ class MediaStorage(object):
_write_file_synchronously, source, fname,
))
# Tell the storage providers about the new file. They'll decide
# if they should upload it and whether to do so synchronously
# or not.
for provider in self.storage_providers:
yield provider.store_file(path, file_info)
defer.returnValue(fname)
@contextlib.contextmanager
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment