Skip to content

Instantly share code, notes, and snippets.

@piotrbernad
Created September 28, 2017 10:33
Show Gist options
  • Save piotrbernad/7784f470d1011369852f0cf17ef1e143 to your computer and use it in GitHub Desktop.
Save piotrbernad/7784f470d1011369852f0cf17ef1e143 to your computer and use it in GitHub Desktop.
KeychainAccessors
struct KeychainAccessors {
/// User's email assign during sign-in
static let email = KeychainAccessor<String>(name: "email",
decoding: { $0.data(using: .utf8) },
encoding: { String(data: $0, encoding: .utf8) }
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment