Use the more abstract api for parsing UsageKeys in mongo/base.py

This commit is contained in:
Calen Pennington
2015-06-09 11:35:26 -04:00
parent 1e0163a27a
commit 984eb0a436

View File

@@ -324,7 +324,7 @@ class CachingDescriptorSystem(MakoDescriptorSystem, EditInfoRuntimeMixin):
"""
Convert a single serialized UsageKey string in a ReferenceField into a UsageKey.
"""
key = Location.from_string(ref_string)
key = UsageKey.from_string(ref_string)
return key.replace(run=self.modulestore.fill_in_run(key.course_key).run)
def __setattr__(self, name, value):