fix richembed set thumbnail func
parent
2674a955b0
commit
fd4cd6a9b3
|
@ -149,7 +149,6 @@ export default class RichEmbed {
|
||||||
*/
|
*/
|
||||||
setThumbnail(url: string) {
|
setThumbnail(url: string) {
|
||||||
if (typeof url !== 'string') throw new TypeError('RichEmbed Thumbnail URLs must be a string.');
|
if (typeof url !== 'string') throw new TypeError('RichEmbed Thumbnail URLs must be a string.');
|
||||||
if (!url.startsWith('http://') || !url.startsWith('https://')) url = `https://${url}`;
|
|
||||||
this.thumbnail = { url };
|
this.thumbnail = { url };
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue