Merge branch 'master' into production

This commit is contained in:
Nick Winter 2014-05-20 08:24:15 -07:00
commit 1cd2035450
2 changed files with 5 additions and 2 deletions

View file

@ -72,6 +72,9 @@ module.exports = class LadderSubmissionView extends CocoView
transpileSession: ->
submittedCode = @session.get('code')
language = @session.get('codeLanguage') or 'javascript'
@session.set('submittedCodeLanguage', language)
@session.save() # TODO: maybe actually use a callback to make sure this works?
transpiledCode = {}
for thang, spells of submittedCode
transpiledCode[thang] = {}
@ -80,7 +83,7 @@ module.exports = class LadderSubmissionView extends CocoView
#DRY this
aetherOptions =
problems: {}
language: "javascript"
language: language
functionName: spellID
functionParameters: []
yieldConditionally: spellID is "plan"

View file

@ -65,7 +65,7 @@ module.exports = class LadderView extends RootView
@insertSubView(@simulateTab = new SimulateTabView())
@refreshInterval = setInterval(@fetchSessionsAndRefreshViews.bind(@), 20 * 1000)
hash = document.location.hash[1..] if document.location.hash
if hash and not (hash in ['my-matches', 'simulate', 'ladder'])
if hash and not (hash in ['my-matches', 'simulate', 'ladder', 'prizes', 'rules'])
@showPlayModal(hash) if @sessions.loaded
fetchSessionsAndRefreshViews: ->