diff --git a/plugins/stats/stats.js b/plugins/stats/stats.js index 39addc03..2079cd0c 100644 --- a/plugins/stats/stats.js +++ b/plugins/stats/stats.js @@ -64,7 +64,7 @@ // percentage helper const percentage = (portion, total) => - ((portion / total) * 100).toFixed(2) + "%"; + (total > 0 ? ((portion / total) * 100).toFixed(2) : 0) + "%"; // *** actual stats fetching *** // performer of scenes with any StashID