Commit 83a3310a by Calen Pennington

Look up data_dir in the metadata, not in the top of the json object when loading from mongodb

parent f61e9aa9
...@@ -141,8 +141,9 @@ class MongoModuleStore(ModuleStore): ...@@ -141,8 +141,9 @@ class MongoModuleStore(ModuleStore):
""" """
Load an XModuleDescriptor from item, using the children stored in data_cache Load an XModuleDescriptor from item, using the children stored in data_cache
""" """
resource_fs = OSFS(self.fs_root / item.get('data_dir', data_dir = item.get('metadata', {}).get('data_dir', item['location']['course'])
item['location']['course'])) resource_fs = OSFS(self.fs_root / data_dir)
system = CachingDescriptorSystem( system = CachingDescriptorSystem(
self, self,
data_cache, data_cache,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment