title: Assigning parsed JSON from SwiftyJSON API shows error
body: <p>I recently updated to <a href="https://en.wikipedia.org/wiki/Swift_%28Apple_programming_language%29" rel="nofollow">Swift</a> from Objective-C, and it's really confusing while parsing JSON in a native way so while searching on Stack&nbsp;Overflow I found the SwiftyJSON API, and it's really cool. I am getting an error while assigning a parsed JSON value to a label. I have stored the result in an array, but while showing it on tableview it shows an error.</p>
  
  <pre><code>//Array where I store the parsed JSON
  var categoryCount = [Int]()
  
  override func viewDidLoad() {
      super.viewDidLoad()
  
      // Do any additional setup after loading the view.
      getData()
  }
  
  func getData() {
  
      Alamofire.request(.GET, "http://www.artively.com/api/MobileApi/get_parent_category")
          .responseJSON { response in
              if let value = response.result.value {
                  let json = JSON(value)
                  self.parseJSON(json)
              }
          }
  }
  
  func parseJSON(json: JSON) {
      for result in json["data"].arrayValue {
          print("The count are",result["product_count"].int!)
          self.categoryCount.append(result["product_count"].int!)
      }
  
      print("The category count are", categoryCount.count)
  }
  </code></pre>
  
  <p>And finally when I execute this code the application crashes:</p>
  
  <pre><code> cell.countLable.text =  "\(categoryCount[indexPath.row])"
        //Error appear in above code
  </code></pre>
  
  <p>This is the JSON result:</p>
  
  <pre><code>{
    "responsecode": "200",
    "responsemsg": "Successfull",
    "data": [
  {
    "pk_category_id": 60,
    "category_name": "Collage",
    "category_logo": "http://www.artively.com//Upload/category_logo/28102015163738_collage_icon.png",
    "category_logo_selected": "http://www.artively.com//Upload/category_logo/28102015163738_collage_icon.png",
    "product_count": 10
  },
  {
    "pk_category_id": 65,
    "category_name": "Contemporary",
    "category_logo": "http://www.artively.com//Upload/category_logo/28102015163521_contempory_icon.png",
    "category_logo_selected": "http://www.artively.com//Upload/category_logo/28102015163521_contempory_icon.png",
    "product_count": 242
  },
  ...So on
  </code></pre>
  
  <p>In the above response I have parsed the value of "product_count", storing it in an array and displaying it on a tableview cell, but the application crashes...</p>