Cap length of debug outputs
This commit is contained in:
parent
4240e978cf
commit
8230fa376b
@ -391,7 +391,7 @@ class MariaDB
|
|||||||
resolve(fields);
|
resolve(fields);
|
||||||
connection.release();
|
connection.release();
|
||||||
});
|
});
|
||||||
this.#logger.debug(`Constructed query: ${q.sql}`);
|
this.#logger.debug(`Constructed query: ${q.sql.substring(0, 1024)}`);
|
||||||
});
|
});
|
||||||
return Promise.resolve(result || []);
|
return Promise.resolve(result || []);
|
||||||
}
|
}
|
||||||
@ -421,7 +421,7 @@ class MariaDB
|
|||||||
let batch = false;
|
let batch = false;
|
||||||
if (values && typeof values.some === 'function')
|
if (values && typeof values.some === 'function')
|
||||||
batch = values.some(val => val instanceof Array);
|
batch = values.some(val => val instanceof Array);
|
||||||
this.#logger.debug(`Incoming query (batch: ${batch})\n${query}\n${inspect(values)}`);
|
this.#logger.debug(`Incoming query (batch: ${batch})\n${query}\n${inspect(values).substring(0, 1024)}`);
|
||||||
|
|
||||||
return this.#_query<T>(query, values ?? [], opts);
|
return this.#_query<T>(query, values ?? [], opts);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user