forked from Galactic/galactic-bot
Convert array buffer to regular buffers through processes
This commit is contained in:
parent
da61ec0712
commit
6ddc625459
@ -172,6 +172,8 @@ class MongoDBProvider extends Provider {
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
|
||||
if(data.buffer) data.buffer = Buffer.from(data.buffer);
|
||||
|
||||
this.db.collection(collection).insertOne(data, (err, result) => {
|
||||
|
||||
if(err) reject(err);
|
||||
|
@ -133,6 +133,8 @@ class MessageCache extends Observer {
|
||||
return null;
|
||||
});
|
||||
|
||||
console.log(buffer);
|
||||
|
||||
if(buffer) {
|
||||
try {
|
||||
const result = await this.client.transactionHandler.send({
|
||||
|
Loading…
Reference in New Issue
Block a user