'Used to update video values during `self`:save method from CMS.
old_metadata: dict, values of fields of `self` with scope=settings which were explicitly set by user.
old_content, same as `old_metadata` but for scope=content.
Due to nature of code flow in item.py::_save_item, before current function is called,
fields of `self` instance have been already updated, but not yet saved.
To obtain values, which were changed by user input,
one should compare own_metadata(self) and old_medatada.
Video player has two tabs, and due to nature of sync between tabs,
metadata from Basic tab is always sent when video player is edited and saved first time, for example:
{\'youtube_id_1_0\': u\'3_yD_cEKoCk\', \'display_name\': u\'Video\', \'sub\': u\'3_yD_cEKoCk\', \'html5_sources\': []},
that\'s why these fields will always present in old_metadata after first save. This should be fixed.
At consequent save requests html5_sources are always sent too, disregard of their change by user.
That means that html5_sources are always in list of fields that were changed (`metadata` param in save_item).
This should be fixed too.'

def editor_saved(self, user, old_metadata, old_content):

    metadata_was_changed_by_user = (old_metadata != own_metadata(self))
    if ((not metadata_was_changed_by_user) and self.sub and hasattr(self, 'html5_sources')):
        html5_ids = get_html5_ids(self.html5_sources)
        for subs_id in html5_ids:
            try:
                Transcript.asset(self.location, subs_id)
            except NotFoundError:
                metadata_was_changed_by_user = True
                break
    if metadata_was_changed_by_user:
        self.edx_video_id = (self.edx_video_id and self.edx_video_id.strip())
        if (self.edx_video_id and edxval_api):
            val_youtube_id = edxval_api.get_url_for_profile(self.edx_video_id, 'youtube')
            if (val_youtube_id and (self.youtube_id_1_0 != val_youtube_id)):
                self.youtube_id_1_0 = val_youtube_id
        manage_video_subtitles_save(self, user, (old_metadata if old_metadata else None), generate_translation=True)
