Skip to content
Snippets Groups Projects
Unverified Commit b3e2a8ef authored by David Ormsbee's avatar David Ormsbee Committed by GitHub
Browse files

Merge pull request #22858 from open-craft/video-field-parsing-fix

Fix: KeyError: 'source' when parsing HTML5 videos
parents cec55074 d39421d9
No related merge requests found
......@@ -617,6 +617,8 @@ class VideoBlock(
video_block = runtime.construct_xblock_from_class(cls, keys)
field_data = cls.parse_video_xml(node)
for key, val in field_data.items():
if key not in cls.fields:
continue # parse_video_xml returns some old non-fields like 'source'
setattr(video_block, key, cls.fields[key].from_json(val))
# Don't use VAL in the new runtime:
video_block.edx_video_id = None
......
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