Update Bot
This commit is contained in:
5
node_modules/mysql2/lib/helpers.js
generated
vendored
5
node_modules/mysql2/lib/helpers.js
generated
vendored
@@ -28,9 +28,10 @@ try {
|
||||
// the purpose of this is to prevent projects using Webpack from displaying a warning during runtime if cardinal is not a dependency
|
||||
const REQUIRE_TERMINATOR = '';
|
||||
highlightFn = require(`cardinal${REQUIRE_TERMINATOR}`).highlight;
|
||||
} catch {
|
||||
} catch (err) {
|
||||
highlightFn = (text) => {
|
||||
if (!cardinalRecommended) {
|
||||
// eslint-disable-next-line no-console
|
||||
console.log('For nicer debug output consider install cardinal@^2.0.0');
|
||||
cardinalRecommended = true;
|
||||
}
|
||||
@@ -42,7 +43,9 @@ try {
|
||||
* Prints debug message with code frame, will try to use `cardinal` if available.
|
||||
*/
|
||||
function printDebugWithCode(msg, code) {
|
||||
// eslint-disable-next-line no-console
|
||||
console.log(`\n\n${msg}:\n`);
|
||||
// eslint-disable-next-line no-console
|
||||
console.log(`${highlightFn(code)}\n`);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user