mirror of
https://github.com/DI0IK/homepage-plus.git
synced 2025-07-09 06:48:47 +00:00
Fix quick launch not opening with accented characters, decoding of characters in suggestions (#2802)
This commit is contained in:
parent
578def33f5
commit
1ddd528bd7
2 changed files with 6 additions and 2 deletions
|
@ -12,7 +12,8 @@ export default async function cachedFetch(url, duration) {
|
|||
return cached;
|
||||
}
|
||||
|
||||
const data = await fetch(url).then((res) => res.json());
|
||||
// wrapping text in JSON.parse to handle utf-8 issues
|
||||
const data = JSON.parse(await fetch(url).then((res) => res.text()));
|
||||
cache.put(url, data, duration * 1000 * 60);
|
||||
return data;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue