mirror of
https://github.com/sudoxnym/habitica-self-host.git
synced 2026-07-18 12:02:54 +00:00
Commented out new dailies behavior
This commit is contained in:
parent
68aedda3bb
commit
e09d4f3a91
2 changed files with 7 additions and 6 deletions
|
|
@ -1502,9 +1502,10 @@ api.wrap = (user, main=true) ->
|
|||
# User is resting at the inn. On cron, buffs are cleared and all dailies are reset without performing damage (fixes issue #5070)
|
||||
if user.preferences.sleep is true
|
||||
user.stats.buffs = clearBuffs
|
||||
user.dailys.forEach (daily) ->
|
||||
daily.completed = false
|
||||
_.each daily.checklist, ((i)->i.completed=false;true)
|
||||
# @TODO: uncomment when new dailies behavior goes live, per https://github.com/HabitRPG/habitrpg/pull/5073#issuecomment-98436542
|
||||
# user.dailys.forEach (daily) ->
|
||||
# daily.completed = false
|
||||
# _.each daily.checklist, ((i)->i.completed=false;true)
|
||||
return
|
||||
|
||||
# Tally each task
|
||||
|
|
|
|||
|
|
@ -175,14 +175,14 @@ describe 'User', ->
|
|||
expect(user.achievements.perfect).to.be 1
|
||||
|
||||
# Handle greyed-out dailys
|
||||
yesterday = moment().subtract(1,'days');
|
||||
yesterday = moment().subtract(1,'days')
|
||||
user.dailys[0].repeat[shared.dayMapping[yesterday.day()]] = 0
|
||||
_.each user.dailys[1..], (d)->d.completed = true
|
||||
cron()
|
||||
expect(user.stats.buffs.str).to.be 1
|
||||
expect(user.achievements.perfect).to.be 2
|
||||
|
||||
describe 'Resting in the Inn', ->
|
||||
describe.skip 'Resting in the Inn', ->
|
||||
user = null
|
||||
cron = null
|
||||
beforeEach ->
|
||||
|
|
@ -553,7 +553,7 @@ describe 'Cron', ->
|
|||
|
||||
describe 'preening', ->
|
||||
beforeEach ->
|
||||
@clock = sinon.useFakeTimers(Date.parse("2013-11-20"), "Date");
|
||||
@clock = sinon.useFakeTimers(Date.parse("2013-11-20"), "Date")
|
||||
|
||||
afterEach ->
|
||||
@clock.restore()
|
||||
|
|
|
|||
Loading…
Reference in a new issue