Skip to content

Commit

Permalink
Add future breakage warning to lookup (#578)
Browse files Browse the repository at this point in the history
  • Loading branch information
frederikrothenberger authored Mar 15, 2022
1 parent 343e411 commit 63eaa6c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/internet_identity/internet_identity.did
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,8 @@ service : (opt InternetIdentityInit) -> {
register : (DeviceData, ChallengeResult) -> (RegisterResponse);
add : (UserNumber, DeviceData) -> ();
remove : (UserNumber, DeviceKey) -> ();
// Returns all devices of the user (authentication and recovery) but no information about device registrations.
// Note: Will be changed in the future to be more consistent with get_anchor_info.
lookup : (UserNumber) -> (vec DeviceData) query;
get_anchor_info : (UserNumber) -> (IdentityAnchorInfo);
get_principal : (UserNumber, FrontendHostname) -> (principal) query;
Expand Down
2 changes: 2 additions & 0 deletions src/internet_identity/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -765,6 +765,8 @@ fn check_challenge(res: ChallengeAttempt) -> Result<(), ()> {
})
}

/// Returns all devices of the user (authentication and recovery) but no information about device registrations.
/// Note: Will be changed in the future to be more consistent with get_anchor_info.
#[query]
fn lookup(user_number: UserNumber) -> Vec<DeviceData> {
STATE.with(|s| {
Expand Down

0 comments on commit 63eaa6c

Please sign in to comment.