         // Dispose of any resources that can be recreated.
     }
     
-    private func getRefAddressBook() -> ABAddressBookRef? {
-        
-        var error:Unmanaged<CFErrorRef>? = nil
-        
-        var addressBook: ABAddressBookRef? = ABAddressBookCreateWithOptions(nil, &error)?.takeRetainedValue()
-        
-        if let addressBook: ABAddressBookRef = addressBook {
-            // success
-            println("Addressbook ref created!")
-        } else {
-            // fail
-            println("Addressbook ref not created")
-        }
-
-        return addressBook
-    }
-    
     private func getOkForAddressBook(addressBook: ABAddressBookRef?) -> Bool {
         
+        println("getOkForAddressBook")
+
         var result: Bool = false
         
         if ABAddressBookGetAuthorizationStatus() == .Authorized {

    
    private func getPersonByNameFromAddressBook(addressBook: ABAddressBookRef?, firstName: String?) -> ABRecordRef? {
        
        var result: ABRecordRef? = nil
        
        let people = ABAddressBookCopyPeopleWithName(addressBook, firstName! as NSString as CFStringRef).takeRetainedValue() as NSArray

    
    private func displayErrorAlert(errorID: Int, tryAgain: Bool) {
        
        println("displayErrorAlert")

        var errorMessage = "I have no idea what the heck is going on!"
        var buttonTitle = "Dismiss"
        var handler: UIAlertAction? = nil
        
        switch errorID {
                        
        case kErrorNotOkToAccessAddressBook:
            
            errorMessage = "If you don't let me access your address book I don't do anything!"
            
        case kErrorHomewardContactMissing:
            
            errorMessage = "You need to create a contact with the first name Homeward and your address!"
            
        default:
            
            println("Hey coder! You are missing an error code!")
            
        }
        
        if tryAgain {
            buttonTitle = "Try Again"
            
            // will need to put handler here
        }
        
        let alert = UIAlertController(title: title, message: errorMessage, preferredStyle: .Alert)
        let action = UIAlertAction(title: buttonTitle, style: .Default, handler: nil)
        
        alert.addAction(action)
        presentViewController(alert, animated: true, completion: nil)

        
    }
