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

Code before:
                video_id = video['id']
                video_url = f'https://www.tiktok.com/@{user_id}/video/{video_id}'
                download_url = try_get(video, (lambda x: x['video']['playAddr'],
                                               lambda x: x['video']['downloadAddr']))
                thumbnail = try_get(video, lambda x: x['video']['originCover'])
                height = try_get(video, lambda x: x['video']['height'], int)
                width = try_get(video, lambda x: x['video']['width'], int)
                yield {
                    'id': video_id,
                    'ie_key': TikTokIE.ie_key(),
                    'extractor': 'TikTok',
                    'url': download_url,
                    'ext': 'mp4',
                    'height': height,
                    'width': width,
                    'title': str_or_none(video.get('desc')),
                    'duration': try_get(video, lambda x: x['video']['duration'], int),
                    'view_count': try_get(video, lambda x: x['stats']['playCount'], int),
                    'like_count': try_get(video, lambda x: x['stats']['diggCount'], int),
                    'comment_count': try_get(video, lambda x: x['stats']['commentCount'], int),
                    'repost_count': try_get(video, lambda x: x['stats']['shareCount'], int),
                    'timestamp': video.get('createTime'),
                    'creator': try_get(video, lambda x: x['author']['nickname'], str),
                    'uploader': try_get(video, lambda x: x['author']['uniqueId'], str),
                    'uploader_id': try_get(video, lambda x: x['author']['id'], str),
                    'uploader_url': 'https://www.tiktok.com/@' + user_id,
                    'thumbnails': [{'url': thumbnail, 'height': height, 'width': width}],
                    'description': str_or_none(video.get('desc')),
                    'webpage_url': video_url,
                    'http_headers': {
                        'Referer': video_url,
                    }
                }
            if not data_json['hasMore']:
                break
            cursor = data_json['cursor']

    def _real_extract(self, url):
        user_id = self._match_id(url)
        return self.playlist_result(self._entries(url, user_id), user_id)


Review comment (suggestion):
```suggestion
                    'uploader_url': f'https://www.tiktok.com/@{user_id}',
```

Code after:
                video_url = f'https://www.tiktok.com/@{user_id}/video/{video_id}'
                download_url = try_get(video, (lambda x: x['video']['playAddr'],
                                               lambda x: x['video']['downloadAddr']))
                thumbnail = try_get(video, lambda x: x['video']['originCover'])
                height = try_get(video, lambda x: x['video']['height'], int)
                width = try_get(video, lambda x: x['video']['width'], int)
                yield {
                    'id': video_id,
                    'ie_key': TikTokIE.ie_key(),
                    'extractor': 'TikTok',
                    'url': download_url,
                    'ext': 'mp4',
                    'height': height,
                    'width': width,
                    'title': str_or_none(video.get('desc')),
                    'duration': try_get(video, lambda x: x['video']['duration'], int),
                    'view_count': try_get(video, lambda x: x['stats']['playCount'], int),
                    'like_count': try_get(video, lambda x: x['stats']['diggCount'], int),
                    'comment_count': try_get(video, lambda x: x['stats']['commentCount'], int),
                    'repost_count': try_get(video, lambda x: x['stats']['shareCount'], int),
                    'timestamp': video.get('createTime'),
                    'creator': try_get(video, lambda x: x['author']['nickname'], str),
                    'uploader': try_get(video, lambda x: x['author']['uniqueId'], str),
                    'uploader_id': try_get(video, lambda x: x['author']['id'], str),
                    'uploader_url': f'https://www.tiktok.com/@{user_id}',
                    'thumbnails': [{'url': thumbnail, 'height': height, 'width': width}],
                    'description': str_or_none(video.get('desc')),
                    'webpage_url': video_url,
                    'http_headers': {
                        'Referer': video_url,
                    }
                }
            if not data_json['hasMore']:
                break
            cursor = data_json['cursor']

    def _real_extract(self, url):
        user_id = self._match_id(url)
        return self.playlist_result(self._entries(url, user_id), user_id)