           problems: {}
           language: "javascript"
           functionName: spellID
-          functionParameters: {}
+          functionParameters: []
           yieldConditionally: spellID is "plan"
           globals: ['Vector', '_']
           protectAPI: true
           includeFlow: false
         aether = new Aether aetherOptions
         transpiledCode[thang][spellID] = aether.transpile spell
-    cb "Prematurely ended"
-    
-  
-  
+        cb null
+    conditions = 
+      "_id": sessionID
+    update = 
+      "transpiledCode"
+    query = LevelSession
+      .update("_id")
 
 findLadderLevelSessions = (levelID, cb) ->
   queryParameters = 
-    level:
-      original: levelID + ""
+    "level.original": levelID + ""
     submitted: true
     
   selectString = "_id"


transpileLevelSession = (sessionID, cb) ->
  query = LevelSession
    .find("_id": sessionID)
    .select("submittedCode")
    .lean()
  query.exec (err, session) ->
    if err then return cb err
    submittedCode = session.submittedCode
    transpiledCode = {}
      
    for thang, spells of submittedCode
      transpiledCode[thang] = {}
      for spellID, spell of spells

  query.exec (err, ladderLevels) ->
    throw err if err
    ladderLevels = _.pluck ladderLevels, "original"
    findLadderLevelSessions ladderLevels[3], (err) ->
      throw err if err
    #async.each ladderLevels, findLadderLevelSessions, (err) ->
    #  throw err if err
serverSetup.connectToDatabase()
transpileLadderSessions()
    
