 	@IBOutlet private var deleteButton: UIBarButtonItem!
 	@IBOutlet private var toolbar: UIToolbar!
 	
-	private var canceled = false
 	private var deleted = false
 	
 	// MARK: Functions

		
		initialCaption = containerView.captionView.getCaption()
		
		let flipButton = UIBarButtonItem(image: #imageLiteral(resourceName: "refresh"), style: .plain, target: containerView, action: #selector(PhotoContainerView.flip))
		let cancelButton = UIBarButtonItem(barButtonSystemItem: .cancel, target: self, action: #selector(cancel))
		navigationItem.setRightBarButtonItems([cancelButton, flipButton], animated: false)
		
		// Don't mess with the captionView insets
		automaticallyAdjustsScrollViewInsets = false

		// Update the Photo object with our changes
		// and kick off a save before we leave the view
		let caption = containerView.captionView.getCaption()
		if !deleted && caption != initialCaption {
			
			photo.caption = caption
			photo.lastUpdated = NSDate()
