             self.setLoadingState(true)
 
             MyDataProvider.getInstance().requestData(offset, size: size,
-                listener: {(items:ViewController.MyItem[]) -> () in
+                listener: {(items:[ViewController.MyItem]) -> () in
                     
                     for item:MyItem in items {
-                        self.items += item
+                        self.items.append(item)
                     }
                     
                     self.tableView.reloadData()

            return MyDataProvider() //return a new instance since class vars not supported yet
        }
        
        func requestData(offset:Int, size:Int, listener:(MyItem[]) -> ()) {
            dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0)) {
                //simulate delay
                sleep(2)
                
                //generate items
                var arr:MyItem[] = []
                for i in offset...(offset + size) {
                    arr += MyItem(name: "Item " + String(i))
                }
                
                //call listener in main thread

    
    @IBOutlet var tableViewFooter:MyFooter!
    
    var items:[MyItem] = []
    
    var loading = false
    
