mirror of
https://github.com/danbulant/discord.js
synced 2026-05-26 05:22:15 +00:00
Use node 8 error code (#1557)
This commit is contained in:
parent
37d6624ef1
commit
a2520efa1a
1 changed files with 1 additions and 1 deletions
|
|
@ -9,7 +9,7 @@ function fetch(Encoder, engineOptions) {
|
|||
try {
|
||||
return new Encoder(engineOptions);
|
||||
} catch (err) {
|
||||
if (err.message.includes('Cannot find module')) return null;
|
||||
if (err.code === 'MODULE_NOT_FOUND') return null;
|
||||
|
||||
// The Opus engine exists, but another error occurred.
|
||||
throw err;
|
||||
|
|
|
|||
Loading…
Reference in a new issue