             attachment.delegate = self
         }
 
+        textStoreString = textStore.string
+
         edited([.editedAttributes, .editedCharacters], range: NSRange(location: 0, length: originalLength), changeInLength: textStore.length - originalLength)
     }
 }

        detectAttachmentRemoved(in: range)
        textStore.replaceCharacters(in: range, with: str)

        edited(.editedCharacters, range: range, changeInLength: str.characters.count - range.length)
        
        endEditing()


    fileprivate var textStore = NSMutableAttributedString(string: "", attributes: nil)

    fileprivate var textStoreString = ""


    // MARK: - Delegates

