 // TODO
 
 
-class MessagingViewController: JSQMessagesViewController {
+class MessagingViewController: JSQMessagesViewController, UIImagePickerControllerDelegate, UINavigationControllerDelegate {
     
     /*===============================================================
         Initialization for the properties

            messageObject.roomy = Roomy.current()
            messageObject.senderName = Roomy.current()?.username
            messageObject.houseID = House._currentHouse
            messageObject.text = text
            
            messageObject.saveInBackground { succeeded, error in
                if succeeded {

        alertVC.addAction(takePhotoAction)
        
        let chooseExistingPhotoAction = UIAlertAction(title: "Choose existing photo", style: .default) { _ in
            let vc = UIImagePickerController()
            vc.delegate = self
            vc.allowsEditing = true
            vc.sourceType = UIImagePickerControllerSourceType.photoLibrary
            
            self.present(vc, animated: true, completion: nil)
        }
        alertVC.addAction(chooseExistingPhotoAction)
        
