mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-03-14 21:31:50 +00:00
fix: crash in JumboCmd error handler
This commit is contained in:
parent
0a3fe2d334
commit
8cee4ec1e4
1 changed files with 7 additions and 1 deletions
|
@ -77,7 +77,13 @@ export const JumboCmd = utilityCmd({
|
|||
} catch (err) {
|
||||
if (url.toLocaleLowerCase().endsWith("fe0f.png")) {
|
||||
url = url.slice(0, url.lastIndexOf("-fe0f")) + ".png";
|
||||
image = await resizeBuffer(await getBufferFromUrl(url), size, size);
|
||||
try {
|
||||
image = resizeBuffer(await getBufferFromUrl(url), size, size);
|
||||
} catch {
|
||||
// It's fine if this fails, we just don't jumbo then.
|
||||
// The errors here are usually some internal errors in the photon WASM code anyway,
|
||||
// so we can't do anything about it.
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!image) {
|
||||
|
|
Loading…
Add table
Reference in a new issue