Fix stocks undefined bug

This commit is contained in:
Dragon Fire
2021-01-17 15:08:11 -05:00
parent 82e1c069e5
commit fad33e81ac
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -79,7 +79,7 @@ module.exports = class StocksCommand extends Command {
interval: '1min',
apikey: ALPHA_VANTAGE_KEY
});
if (body['Error Message']) return null;
if (body['Error Message'] || !body['Time Series (1min)']) return null;
const data = Object.values(body['Time Series (1min)'])[0];
return {
symbol,
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "xiao",
"version": "126.6.0",
"version": "126.6.1",
"description": "Your personal server companion.",
"main": "Xiao.js",
"scripts": {