mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-25 14:21:41 +02:00
Fix Steam
This commit is contained in:
@@ -35,7 +35,7 @@ module.exports = class SteamCommand extends Command {
|
|||||||
const { body } = await request
|
const { body } = await request
|
||||||
.get('https://store.steampowered.com/api/appdetails')
|
.get('https://store.steampowered.com/api/appdetails')
|
||||||
.query({ appids: id });
|
.query({ appids: id });
|
||||||
const { data } = body[id.toString()];
|
const { data } = body[id.toString()] || body[id];
|
||||||
const current = data.price_overview ? `$${data.price_overview.final / 100}` : 'Free';
|
const current = data.price_overview ? `$${data.price_overview.final / 100}` : 'Free';
|
||||||
const original = data.price_overview ? `$${data.price_overview.initial / 100}` : 'Free';
|
const original = data.price_overview ? `$${data.price_overview.initial / 100}` : 'Free';
|
||||||
const price = current === original ? current : `~~${original}~~ ${current}`;
|
const price = current === original ? current : `~~${original}~~ ${current}`;
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "xiao",
|
"name": "xiao",
|
||||||
"version": "84.4.1",
|
"version": "84.4.2",
|
||||||
"description": "Your personal server companion.",
|
"description": "Your personal server companion.",
|
||||||
"main": "Xiao.js",
|
"main": "Xiao.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
Reference in New Issue
Block a user