openmls icon indicating copy to clipboard operation
openmls copied to clipboard

Introduce LeafOrEncryptionKey for update_and_resign on LeafNode

Open franziskuskiefer opened this issue 1 year ago • 0 comments

          This might be a bit overkill, but can't wouldn't it be nicer to introduce an enum (e.g. `LeafOrEncryptionKey` here that is either a leaf node or an encryption key and that has a `From` implementation from both? We could then use an impl Into<LeafOrEncryptionKey> as input instead of the two options. That would mean that we wouldn't have this awkward double-option setup and the caller still wouldn't have to worry about constructing the enum externally.

Originally posted by @kkohbrok in https://github.com/openmls/openmls/pull/1227#discussion_r1091556468

franziskuskiefer avatar Jan 31 '23 08:01 franziskuskiefer