Fix quick launch not opening with accented characters, decoding of characters in suggestions (#2802)
This commit is contained in:
1 parent
578def33f5
commit
1ddd528bd7
2 files changed
+6
-2
No files matched your search
@@ -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;
|
||||
}
|
||||
Reference in new issue
Block a user