Skip to content
Snippets Groups Projects

Resolve "Migrate to Symfony framework"

Merged Benoît Harrault requested to merge 28-migrate-to-symfony-framework into master
81 files
+ 16099
790
Compare changes
  • Side-by-side
  • Inline
Files
81
var lastFetchedNowPlayingData = "";
var lastFetchedNowPlayingData = "";
function updateNowPlaying() {
function updateNowPlaying() {
var apiUrl = "now-playing?api";
var apiUrl = "now-playing/data";
var newContent = fetch(apiUrl)
var newContent = fetch(apiUrl)
.then(function (response) {
.then(function (response) {
@@ -80,5 +80,7 @@ function buildNowPlayingBlock(apiResponse) {
@@ -80,5 +80,7 @@ function buildNowPlayingBlock(apiResponse) {
return html;
return html;
}
}
updateNowPlaying();
if (document.getElementById("now-playing")) {
setInterval(updateNowPlaying, 2000);
updateNowPlaying();
 
setInterval(updateNowPlaying, 3000);
 
}
Loading