string should be a number

merge-requests/1/merge
Matthew 2019-11-17 18:13:17 -05:00
parent 51839c20eb
commit 2b2b4f6830
No known key found for this signature in database
GPG Key ID: 766BE43AE75F7559
1 changed files with 1 additions and 1 deletions

View File

@ -47,7 +47,7 @@ export default class Account extends Route {
this.router.get('/storage', async (req: Req, res) => {
try {
const data = await this.server.client.redis.get(`storage-${req.account.username}`) ? await this.server.client.redis.get(`storage-${req.account.username}`) : null;
const data = await this.server.client.redis.get(`storage-${req.account.username}`) ? Number(await this.server.client.redis.get(`storage-${req.account.username}`)) : null;
res.status(200).json({ code: this.constants.codes.SUCCESS, message: data });
} catch (error) {
this.handleError(error, res);