Repository: yt-dlp/yt-dlp
File: yt_dlp/extractor/instagram.py (Python)

Code before:
                            'title': node.get('title') or 'Video %d' % edge_num,
                            'url': node_video_url,
                            'thumbnail': node.get('display_url'),
                            'duration': float_or_none(node.get('video_duration')),
                            'width': int_or_none(try_get(node, lambda x: x['dimensions']['width'])),
                            'height': int_or_none(try_get(node, lambda x: x['dimensions']['height'])),
                            'view_count': int_or_none(node.get('video_view_count')),
                        })
                    return self.playlist_result(
                        entries, video_id,
                        'Post by %s' % uploader_id if uploader_id else None,
                        description)

        if not video_url:
            video_url = self._og_search_video_url(webpage, secure=False)

        formats = [{
            'url': video_url,
            'width': width,
            'height': height,
        }]
        dash = try_get(media, lambda x: x['dash_info']['video_dash_manifest'])
        if dash:
            additional_formats = self._parse_mpd_formats(self._parse_xml(dash, video_id), mpd_id='dash')
            formats += additional_formats
            self._sort_formats(formats)

        if not uploader_id:
            uploader_id = self._search_regex(
                r'"owner"\s*:\s*{\s*"username"\s*:\s*"(.+?)"',
                webpage, 'uploader id', fatal=False)

        if not description:
            description = self._search_regex(
                r'"caption"\s*:\s*"(.+?)"', webpage, 'description', default=None)
            if description is not None:
                description = lowercase_escape(description)

        if not thumbnail:
            thumbnail = self._og_search_thumbnail(webpage)

        return {
            'id': video_id,
            'formats': formats,
            'ext': 'mp4',
            'title': title or 'Video by %s' % uploader_id,
            'description': description,
            'duration': duration,
            'thumbnail': thumbnail,
            'timestamp': timestamp,
            'uploader_id': uploader_id,

Review comment (suggestion):
```suggestion
        dash = try_get(media, lambda x: x['dash_info']['video_dash_manifest'])
        if dash:
            formats.extend(self._parse_mpd_formats(self._parse_xml(dash, video_id), mpd_id='dash'))
        self._sort_formats(formats)
```

Code after:
                            'title': node.get('title') or 'Video %d' % edge_num,
                            'url': node_video_url,
                            'thumbnail': node.get('display_url'),
                            'duration': float_or_none(node.get('video_duration')),
                            'width': int_or_none(try_get(node, lambda x: x['dimensions']['width'])),
                            'height': int_or_none(try_get(node, lambda x: x['dimensions']['height'])),
                            'view_count': int_or_none(node.get('video_view_count')),
                        })
                    return self.playlist_result(
                        entries, video_id,
                        'Post by %s' % uploader_id if uploader_id else None,
                        description)

        if not video_url:
            video_url = self._og_search_video_url(webpage, secure=False)

        formats = [{
            'url': video_url,
            'width': width,
            'height': height,
        }]
        dash = try_get(media, lambda x: x['dash_info']['video_dash_manifest'])
        if dash:
            formats.extend(self._parse_mpd_formats(self._parse_xml(dash, video_id), mpd_id='dash'))
        self._sort_formats(formats)

        if not uploader_id:
            uploader_id = self._search_regex(
                r'"owner"\s*:\s*{\s*"username"\s*:\s*"(.+?)"',
                webpage, 'uploader id', fatal=False)

        if not description:
            description = self._search_regex(
                r'"caption"\s*:\s*"(.+?)"', webpage, 'description', default=None)
            if description is not None:
                description = lowercase_escape(description)

        if not thumbnail:
            thumbnail = self._og_search_thumbnail(webpage)

        return {
            'id': video_id,
            'formats': formats,
            'ext': 'mp4',
            'title': title or 'Video by %s' % uploader_id,
            'description': description,
            'duration': duration,
            'thumbnail': thumbnail,
            'timestamp': timestamp,
            'uploader_id': uploader_id,
            'uploader': uploader,