mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-04 01:29:21 +00:00
confirm "trigger new day"
This commit is contained in:
parent
4e668a7de4
commit
4b35551afc
1 changed files with 1 additions and 0 deletions
|
|
@ -45,6 +45,7 @@ habitrpg.controller("FooterCtrl", ['$scope', '$rootScope', 'User', '$http', 'Not
|
|||
* Debug functions. Note that the server route for gems is only available if process.env.DEBUG=true
|
||||
*/
|
||||
$scope.addMissedDay = function(){
|
||||
if (!confirm("Are you sure you want to reset the day?")) return;
|
||||
var dayBefore = moment(User.user.lastCron).subtract('days', 1).toDate();
|
||||
User.set('lastCron', dayBefore);
|
||||
Notification.text('-1 day, remember to refresh');
|
||||
|
|
|
|||
Loading…
Reference in a new issue