Don't insert ListenBrainz element if no listens are available.
This commit is contained in:
parent
203e37c35f
commit
a03db59c65
|
@ -6,6 +6,10 @@ window.addEventListener('DOMContentLoaded', async () => {
|
|||
}
|
||||
|
||||
const data = await result.json();
|
||||
if (data.payload.listens.length === 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
const listen = data.payload.listens[0];
|
||||
const listenHtml = `<div class="divider"></div><div class="listenbrainz">
|
||||
<a href="https://listenbrainz.org/user/BaukeXYZ/" target="_blank">
|
||||
|
|
Loading…
Reference in New Issue