Make currentEventAttachment id-based, not index-based
Buffer settings are set according to buffer id
Return undone event from undoEventSessionId instead of a boolean