mirror of
https://github.com/MetaFam/TheGame.git
synced 2026-01-25 14:17:56 -05:00
Made xp weekly change more readable (#569)
This commit is contained in:
@@ -49,6 +49,7 @@ export class GetXpCommand {
|
||||
const userTotalCred = scAccount.totalCred;
|
||||
const numWeeks = scAccount.cred.length;
|
||||
const userWeeklyCred = scAccount.cred;
|
||||
|
||||
const variation =
|
||||
(100 *
|
||||
(userWeeklyCred[numWeeks - 1] - userWeeklyCred[numWeeks - 2])) /
|
||||
@@ -87,7 +88,7 @@ export class GetXpCommand {
|
||||
},
|
||||
{
|
||||
name: 'Weekly Change',
|
||||
value: `${variation.toPrecision(2)}%`,
|
||||
value: `${Math.round(variation)}%`,
|
||||
inline: true,
|
||||
},
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user