channelThumbnail: don't resolve if already in process

This commit is contained in:
infinite-persistence 2021-11-03 22:49:27 +08:00
parent 60a0d6d31a
commit 531a87e969
No known key found for this signature in database
GPG key ID: B9C3252EDC3D0AA0

View file

@ -49,7 +49,7 @@ function ChannelThumbnail(props: Props) {
ThumbUploadError,
} = props;
const [thumbLoadError, setThumbLoadError] = React.useState(ThumbUploadError);
const shouldResolve = claim === undefined;
const shouldResolve = !isResolving && claim === undefined;
const thumbnail = rawThumbnail && rawThumbnail.trim().replace(/^http:\/\//i, 'https://');
const thumbnailPreview = rawThumbnailPreview && rawThumbnailPreview.trim().replace(/^http:\/\//i, 'https://');
const defaultAvatar = AVATAR_DEFAULT || Gerbil;