 # methods
 
 checkChallenges = (challenges) ->
+  console.log "checkChallenges"
   # check for results
-  for c in challenges
-    continue unless c.challengerId is currentPlayerId()
+  challenges.forEach (c) ->
+    console.log "check result: #{c}"
+    unless c.challengerId is currentPlayerId()
+      console.log 'continue'
+      return true
 
     challengerGame = Games.findOne c.challengerGameId
     challengeeGame = Games.findOne c.challengeeGameId

        cancel:  "Nei takk"
        confirm: "Aksepter dyst"

      return

startGame = ({challengeeId, acceptChallengeId}) ->
  Meteor.call 'newGame', currentPlayerId(),


      Challenges.update currentChallenge()._id, $set: { notified: true }

      console.log "break"
      return false

  challenges.rewind()

  # check for challenges
  challenges.forEach (c) ->
    console.log "check challenge: #{c}"
    unless c.challengeeId is currentPlayerId()
      console.log 'continue'
      return true

    challengerGame = Games.findOne c.challengerGameId
    challengeeGame = Games.findOne c.challengeeGameId
