mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-19 07:37:25 +01:00
Fixed login counter on the first day
This commit is contained in:
@@ -94,6 +94,7 @@ habitrpg.controller("UserCtrl", ['$rootScope', '$scope', '$location', 'User', '$
|
|||||||
$scope.getProgressDisplay = function () {
|
$scope.getProgressDisplay = function () {
|
||||||
var currentLoginDay = Content.loginIncentives[$scope.profile.loginIncentives];
|
var currentLoginDay = Content.loginIncentives[$scope.profile.loginIncentives];
|
||||||
var nextRewardAt = currentLoginDay.nextRewardAt;
|
var nextRewardAt = currentLoginDay.nextRewardAt;
|
||||||
|
if (!currentLoginDay.prevRewardKey) currentLoginDay.prevRewardKey = 0;
|
||||||
return ' ' + ($scope.profile.loginIncentives - currentLoginDay.prevRewardKey) + '/' + (nextRewardAt - currentLoginDay.prevRewardKey);
|
return ' ' + ($scope.profile.loginIncentives - currentLoginDay.prevRewardKey) + '/' + (nextRewardAt - currentLoginDay.prevRewardKey);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user