Skip to content

Clarifications about userHandle computation in FinishAssertionSteps class #243

Answered by emlun
CyrilCadoux asked this question in Q&A
Discussion options

You must be logged in to vote

Hi!

  1. This is a work-around to the fact that unlike scala.Option, java.util.Optional doesn't have a method like .orElse(Option<T>), where the fallback is also an Optional. Instead, we work around it by wrapping any present value in another layer of Optional, so we can use .orElseGet() to get the original value back if it was present, or otherwise return a different Optional value.

  2. This is a known bug in Safari - an empty user handle is distinct from a null/undefined user handle. Second-factor credentials typically do not return a user handle, so Safari should be setting it to null/undefined instead of an empty byte array.

    We do not intend to add a workaround for this in the library, but…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@CyrilCadoux
Comment options

Answer selected by CyrilCadoux
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants