From f9c2338dd29865d1200609e9b0b85921b1bb8f12 Mon Sep 17 00:00:00 2001 From: Fauvet Matthis Date: Fri, 21 Jun 2024 16:40:36 +0200 Subject: [PATCH] modified code --- onzer.riot | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/onzer.riot b/onzer.riot index f3185c2..22135d8 100644 --- a/onzer.riot +++ b/onzer.riot @@ -71,13 +71,12 @@ async list(){ let data = await this.fetchData(); this.state = { - placeholder: "Rechercher dans les songs", items: data.results }; this.update(); }, fetchData(){ - return fetch("https://dwarves.iut-fbleau.fr/~fauvet/api/songs").then(response => { + return fetch("https://dwarves.iut-fbleau.fr/~fauvet/api/"+this.state.search).then(response => { return response.json(); }); },