title: SwiftyJSON keeps returning empty objects
body: <p>I am new to <a href="https://github.com/lingoer/SwiftyJSON" rel="nofollow">SwiftyJSON</a>, and I'm having some trouble with it. I can get it to return the entire JSON file as a string, but the moment I try to parse it, I keep getting empty variables back, and I'm not sure what I'm doing wrong.</p>
  
  <p>This is the formatting of my JSON file:</p>
  
  <pre><code>[
      {
          "entryID": 1,
          "from": "String",
          "to": "String",
          "value": "String"
      },
      {
          ...
      },
      ...
  ]
  </code></pre>
  
  <p>And this is roughly what I want to do with it (in quite inelegant code, I do apologise, I'm new to Swift):</p>
  
  <pre><code>for entry: JSON in indexJSON.arrayValue {
  
      var vEntryID: Int
      var vFrom: String
      var vTo: String
      var vValue: String
      for (dictKey: String, dictVal: JSON) in entry.dictionaryValue {
          if(dictKey=="entryID") {vEntryID = dictVal.intValue}
          if(dictKey=="from") {vFrom = dictVal.stringValue}
          if(dictKey=="to") {vTo = dictVal.stringValue}
          if(dictKey=="value") {vValue = dictVal.stringValue}
      }
  
      someSwiftObject[vEntryID]["from"] = vFrom
      someSwiftObject[vEntryID]["to"] = vTo
      someSwiftObject[vEntryID]["value"] = vValue
  }
  </code></pre>
  
  <p>However, this block never executes at all, because indexJSON.arrayValue is always empty.</p>
  
  <p>When I try to run the following, it correctly prints the complete file contents to the console:</p>
  
  <pre><code>let indexJSON = JSON(content!)
  println(indexJSON.stringValue)
  </code></pre>
  
  <p>But when I try to go deeper, to fetch any element, it returns nothing:</p>
  
  <pre><code>if(indexJSON.arrayValue.isEmpty==true) {println("indexJSON.arrayValue is Empty")}
  if(indexJSON[0].arrayValue.isEmpty==true) {println("indexJSON[0].arrayValue is Empty")}
  if(indexJSON[0].dictionaryValue.isEmpty==true) {println("indexJSON[0].dictionaryValue is Empty")}
  if(indexJSON[0]["entryID"]==nil) {println("indexJSON[0][\"entryID\"].stringValue is Empty")}
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>indexJSON.arrayValue is Empty
  indexJSON[0].arrayValue is Empty
  indexJSON[0].dictionaryValue is Empty
  indexJSON[0]["entryID"].stringValue is Empty
  </code></pre>
  
  <p>I'd be grateful for any help! What am I doing wrong?</p>