From 4434016e5c3e0281cfb9f0e028584566628e20c5 Mon Sep 17 00:00:00 2001 From: Navy Date: Thu, 16 Apr 2020 14:03:05 +0300 Subject: [PATCH] Change message.query to message.request --- storage/StorageManager.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/storage/StorageManager.js b/storage/StorageManager.js index 78a34c9..80168bc 100644 --- a/storage/StorageManager.js +++ b/storage/StorageManager.js @@ -45,9 +45,9 @@ class StorageManager { if(!message.provider) return this._send(shard, { error: true, message: "Provider not provided", transactionID: message.transactionID }); if(!this.providers.has(message.provider)) return this._send(shard, { error: true, message: `Invalid provider, expected 'mongodb' or 'mariadb', got '${message.provider}'`, transactionID: message.transactionID }); - if(!message.query) return this._send(shard, { error: true, message: `Missing query.`, transactionID: message.transactionID }); + if(!message.request) return this._send(shard, { error: true, message: `Missing query.`, transactionID: message.transactionID }); - const response = await this.providers.get(message.provider)._query(message.query); + const response = await this.providers.get(message.provider)._query(message.request); if(response.error) { this.manager.logger.write('error', `Provider ${message.provider} errored: ${response.message}`, shard);