From 3de45bbe183b9fd930b6153419ca2e9806b711b6 Mon Sep 17 00:00:00 2001 From: Reinder Nijhoff Date: Wed, 27 Mar 2024 14:22:09 +0100 Subject: [PATCH] Update dittytoyMediaSession.js --- example/src/dittytoyMediaSession.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/example/src/dittytoyMediaSession.js b/example/src/dittytoyMediaSession.js index 4e2f83b..23a9475 100644 --- a/example/src/dittytoyMediaSession.js +++ b/example/src/dittytoyMediaSession.js @@ -91,12 +91,12 @@ export function initDittytoyMediaSession(dittytoy, prev = null, next = null) { export function setMediaSessionMetadata({title, artist, album, artwork}) { try { - navigator.mediaSession.metadata = new MediaMetadata({ - title, - artist, - album, - artwork: artwork.map(({src, sizes, type}) => ({src, sizes, type})), - }); + navigator.mediaSession.metadata = new MediaMetadata({ + title, + artist, + album, + artwork: artwork.map(({src, sizes, type}) => ({src, sizes, type})), + }); } catch (error) { console.log(`The media session metadata is not supported yet.`); }