mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-07-13 15:38:59 +00:00
chore(moment): upgrade moment, run grunt
This commit is contained in:
parent
1e9c1295e5
commit
a699c2924e
2 changed files with 12 additions and 6 deletions
16
dist/habitrpg-shared.js
vendored
16
dist/habitrpg-shared.js
vendored
|
|
@ -13451,7 +13451,9 @@ api.startOfDay = function(options) {
|
||||||
options = {};
|
options = {};
|
||||||
}
|
}
|
||||||
o = sanitizeOptions(options);
|
o = sanitizeOptions(options);
|
||||||
return moment(o.now).startOf('day').add('h', o.dayStart);
|
return moment(o.now).startOf('day').add({
|
||||||
|
hours: o.dayStart
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
api.dayMapping = {
|
api.dayMapping = {
|
||||||
|
|
@ -13503,7 +13505,9 @@ api.shouldDo = function(day, repeat, options) {
|
||||||
if (options.dayStart <= o.now.hour()) {
|
if (options.dayStart <= o.now.hour()) {
|
||||||
return selected;
|
return selected;
|
||||||
} else {
|
} else {
|
||||||
yesterday = moment(o.now).subtract(1, 'd').day();
|
yesterday = moment(o.now).subtract({
|
||||||
|
days: 1
|
||||||
|
}).day();
|
||||||
return repeat[api.dayMapping[yesterday]];
|
return repeat[api.dayMapping[yesterday]];
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
@ -15299,7 +15303,9 @@ api.wrap = function(user, main) {
|
||||||
scheduleMisses = 0;
|
scheduleMisses = 0;
|
||||||
_.times(daysMissed, function(n) {
|
_.times(daysMissed, function(n) {
|
||||||
var thatDay;
|
var thatDay;
|
||||||
thatDay = moment(now).subtract('days', n + 1);
|
thatDay = moment(now).subtract({
|
||||||
|
days: n + 1
|
||||||
|
});
|
||||||
if (api.shouldDo(thatDay, repeat, user.preferences)) {
|
if (api.shouldDo(thatDay, repeat, user.preferences)) {
|
||||||
return scheduleMisses++;
|
return scheduleMisses++;
|
||||||
}
|
}
|
||||||
|
|
@ -15489,5 +15495,5 @@ api.wrap = function(user, main) {
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
}).call(this,require("/home/matteo/Dev/habitrpg/habitrpg-shared/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js"))
|
}).call(this,require("/Users/lefnire/Dropbox/Sites/habitrpg/modules/habitrpg-shared/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js"))
|
||||||
},{"./content.coffee":5,"./i18n.coffee":6,"/home/matteo/Dev/habitrpg/habitrpg-shared/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js":2,"lodash":3,"moment":4}]},{},[1])
|
},{"./content.coffee":5,"./i18n.coffee":6,"/Users/lefnire/Dropbox/Sites/habitrpg/modules/habitrpg-shared/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js":2,"lodash":3,"moment":4}]},{},[1])
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
"browserify": "~3.30.2",
|
"browserify": "~3.30.2",
|
||||||
"coffeeify": "0.6.0",
|
"coffeeify": "0.6.0",
|
||||||
"coffee-script": "1.7.1",
|
"coffee-script": "1.7.1",
|
||||||
"moment": "~2.4.0",
|
"moment": "~2.8.3",
|
||||||
"lodash": "~2.4.1",
|
"lodash": "~2.4.1",
|
||||||
"grunt-spritesmith": "~1.22.0"
|
"grunt-spritesmith": "~1.22.0"
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue