Skip to content

Commit

Permalink
fix: axios error
Browse files Browse the repository at this point in the history
  • Loading branch information
akvlad committed Apr 18, 2024
1 parent 88bd91a commit df8bc6f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/db/clickhouse.js
Original file line number Diff line number Diff line change
Expand Up @@ -1363,7 +1363,7 @@ const samplesReadTable = {
*/
const rawRequest = async (query, data, database, config) => {
try {
if (!(Buffer.isBuffer(data) || data instanceof Uint8Array || typeof data === 'string')) {
if (data && !(Buffer.isBuffer(data) || data instanceof Uint8Array || typeof data === 'string')) {
throw new Error('data must be Buffer, Uint8Array or String: currently the data is: ' + typeof data)
}
if (typeof query !== 'string') {
Expand Down

0 comments on commit df8bc6f

Please sign in to comment.