                     }
                 }
             }
+        }
+    }
+    
+    func fetchData() {
+        let fetchRequest = NSFetchRequest(entityName: USER_ENTITY)
+        
+        do {
+            let results =
+            try DELEGATE.managedObjectContext.executeFetchRequest(fetchRequest)
+            
+            users = results as! [User!]
+
+            self.tableView.reloadData()
+            self.tableView.reloadInputViews()
+            
+        } catch let error as NSError {
+            print("\(FETCH_ERR)\(error),\(error.userInfo)")
         }
     }
     

    
    override func viewWillAppear(animated: Bool) {
        super.viewWillAppear(animated)
        
        let fetchRequest = NSFetchRequest(entityName: USER_ENTITY)
        
        do {
            let results =
            try DELEGATE.managedObjectContext.executeFetchRequest(fetchRequest)
            
            users = results as! [User!]
            
        } catch let error as NSError {
            print("\(FETCH_ERR)\(error),\(error.userInfo)")
        }
    }
    
    override func viewDidLoad() {

            if (success) {
                APIClient.shared.getUsers(TOKEN) { (success, error) -> Void in
                    if(success) {
                        self.fetchData()
                    }
                }
            }
