-
Notifications
You must be signed in to change notification settings - Fork 83
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
67f38e4
commit e519e17
Showing
3 changed files
with
32 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ | |
* More detail regarding the MySQL module can be found here: | ||
* https://github.com/mysqljs/mysql | ||
* @author Jeremy Daly <[email protected]> | ||
* @version 1.5.3 | ||
* @version 1.5.4 | ||
* @license MIT | ||
*/ | ||
|
||
|
@@ -191,7 +191,11 @@ module.exports = (params) => { | |
client.destroy() // destroy connection on timeout | ||
resetClient() // reset the client | ||
reject(err) // reject the promise with the error | ||
} else if (err && (/^PROTOCOL_ENQUEUE_AFTER_/.test(err.code) || err.code === 'PROTOCOL_CONNECTION_LOST' || err.code === 'EPIPE')) { | ||
} else if ( | ||
err && (/^PROTOCOL_ENQUEUE_AFTER_/.test(err.code) | ||
|| err.code === 'PROTOCOL_CONNECTION_LOST' | ||
|| err.code === 'EPIPE') | ||
) { | ||
resetClient() // reset the client | ||
return resolve(query(...args)) // attempt the query again | ||
} else if (err) { | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters