mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2025-04-28 15:03:57 -04:00
Make sessions a little more likely to save if we're not in production.
This commit is contained in:
parent
a21a2f7c8f
commit
595ca17c05
1 changed files with 4 additions and 2 deletions
|
@ -29,8 +29,10 @@ module.exports = class LevelBus extends Bus
|
||||||
constructor: ->
|
constructor: ->
|
||||||
super(arguments...)
|
super(arguments...)
|
||||||
@changedSessionProperties = {}
|
@changedSessionProperties = {}
|
||||||
#@saveSession = _.debounce(@reallySaveSession, 1000, {maxWait: 5000}) # not during HoC apparently
|
if document.location.href.search('codecombat.com') isnt -1
|
||||||
@saveSession = _.debounce(@reallySaveSession, 10000, {maxWait: 30000})
|
@saveSession = _.debounce(@reallySaveSession, 10000, {maxWait: 30000}) # Save us during HoC
|
||||||
|
else
|
||||||
|
@saveSession = _.debounce(@reallySaveSession, 1000, {maxWait: 5000}) # Not this fast during HoC
|
||||||
@playerIsIdle = false
|
@playerIsIdle = false
|
||||||
|
|
||||||
init: ->
|
init: ->
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue