Commit 78a29595 by Mat Peterson Committed by Diana Huang

Removed some definition_key references

parent 4f6088cb
......@@ -56,7 +56,7 @@ def path_to_location(modulestore, usage_key):
parent = modulestore.get_parent_location(next_usage)
# print 'Processing loc={0}, path={1}'.format(next_usage, path)
if next_usage.definition_key.block_type == "course":
if next_usage.block_type == "course":
# Found it!
path = (next_usage, path)
return flatten(path)
......@@ -92,7 +92,7 @@ def path_to_location(modulestore, usage_key):
if n > 3:
position_list = []
for path_index in range(2, n - 1):
category = path[path_index].definition_key.block_type
category = path[path_index].block_type
if category == 'sequential' or category == 'videosequence':
section_desc = modulestore.get_item(path[path_index])
child_locs = [c.location for c in section_desc.get_children()]
......
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