mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-05-23 22:27:06 +00:00
typo on corrupt task cleanup
This commit is contained in:
parent
fe9c56f189
commit
c40ec44644
3 changed files with 556 additions and 558 deletions
File diff suppressed because one or more lines are too long
|
|
@ -263,7 +263,7 @@ try {
|
|||
}
|
||||
if (!_.isNumber(value) || _.isNaN(value)) {
|
||||
task.value = value = 0;
|
||||
paths["task." + task.id + ".value"] = true;
|
||||
paths["tasks." + task.id + ".value"] = true;
|
||||
}
|
||||
if (task.value > user.stats.gp && task.type === 'reward') {
|
||||
return;
|
||||
|
|
@ -552,7 +552,7 @@ try {
|
|||
}).call(this);
|
||||
|
||||
|
||||
},{"./items.coffee":3,"./helpers.coffee":4,"moment":5,"lodash":6}],3:[function(require,module,exports){
|
||||
},{"./helpers.coffee":4,"./items.coffee":3,"moment":5,"lodash":6}],3:[function(require,module,exports){
|
||||
(function() {
|
||||
var items, _;
|
||||
|
||||
|
|
@ -1675,7 +1675,7 @@ process.chdir = function (dir) {
|
|||
|
||||
|
||||
})(require("__browserify_process"))
|
||||
},{"./items.coffee":3,"moment":5,"lodash":6,"relative-date":8,"__browserify_process":7}],5:[function(require,module,exports){
|
||||
},{"./items.coffee":3,"lodash":6,"moment":5,"relative-date":8,"__browserify_process":7}],5:[function(require,module,exports){
|
||||
(function(){// moment.js
|
||||
// version : 2.0.0
|
||||
// author : Tim Wood
|
||||
|
|
|
|||
|
|
@ -158,12 +158,12 @@ randomDrop = (user, delta, priority, streak = 0, options={}) ->
|
|||
# Tier 3 (Rare)
|
||||
else if rarity < .3
|
||||
acceptableDrops = ['Base', 'White', 'Desert', 'Red', 'Shade', 'Skeleton']
|
||||
|
||||
|
||||
# Commented out for testing with increased egg drop, delete if successful
|
||||
# Tier 2 (Scarce)
|
||||
# else if rarity < .4
|
||||
# acceptableDrops = ['Base', 'White', 'Desert']
|
||||
|
||||
|
||||
# Tier 1 (Common)
|
||||
else
|
||||
acceptableDrops = ['Base', 'White', 'Desert']
|
||||
|
|
@ -195,7 +195,7 @@ obj.score = (user, task, direction, options={}) ->
|
|||
return 0 unless task.id
|
||||
if !_.isNumber(value) or _.isNaN(value)
|
||||
task.value = value = 0;
|
||||
paths["task.#{task.id}.value"] = true
|
||||
paths["tasks.#{task.id}.value"] = true
|
||||
|
||||
# If they're trying to purhcase a too-expensive reward, don't allow them to do that.
|
||||
if task.value > user.stats.gp and task.type is 'reward'
|
||||
|
|
@ -408,5 +408,3 @@ obj.cron = (user, options={}) ->
|
|||
(user.history.exp ?= []).push { date: now, value: expTally }
|
||||
paths["history"] = true
|
||||
user
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue