Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3301740
D11546.id38887.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D11546.id38887.diff
View Options
diff --git a/services/identity/src/grpc_services/authenticated.rs b/services/identity/src/grpc_services/authenticated.rs
--- a/services/identity/src/grpc_services/authenticated.rs
+++ b/services/identity/src/grpc_services/authenticated.rs
@@ -198,12 +198,14 @@
identity_info: Some(identity_info),
});
- let keyserver_info = self
+ let Some(keyserver_info) = self
.db_client
.get_keyserver_keys_for_user(&message.user_id)
.await
.map_err(handle_db_error)?
- .map(OutboundKeyInfo::from);
+ else {
+ return Err(Status::not_found("keyserver not found"));
+ };
let primary_device_data = self
.db_client
@@ -213,7 +215,7 @@
let primary_device_keys = primary_device_data.device_key_info;
let response = Response::new(KeyserverKeysResponse {
- keyserver_info,
+ keyserver_info: Some(keyserver_info.into()),
identity,
primary_device_identity_info: Some(primary_device_keys.into()),
});
diff --git a/shared/protos/identity_auth.proto b/shared/protos/identity_auth.proto
--- a/shared/protos/identity_auth.proto
+++ b/shared/protos/identity_auth.proto
@@ -116,7 +116,7 @@
}
message KeyserverKeysResponse {
- optional OutboundKeyInfo keyserver_info = 1;
+ OutboundKeyInfo keyserver_info = 1;
Identity identity = 2;
identity.unauth.IdentityKeyInfo primary_device_identity_info = 3;
}
diff --git a/web/protobufs/identity-auth-structs.cjs.flow b/web/protobufs/identity-auth-structs.cjs.flow
--- a/web/protobufs/identity-auth-structs.cjs.flow
+++ b/web/protobufs/identity-auth-structs.cjs.flow
@@ -170,7 +170,7 @@
}
export type KeyserverKeysResponseObject = {
- keyserverInfo?: OutboundKeyInfoObject,
+ keyserverInfo: ?OutboundKeyInfoObject,
identity: ?IdentityObject,
primaryDeviceIdentityInfo: ?identityStructs.IdentityKeyInfoObject,
};
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 19, 3:43 AM (19 h, 54 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2536311
Default Alt Text
D11546.id38887.diff (1 KB)
Attached To
Mode
D11546: [protos][identity] Make keyserver_info response non-optional
Attached
Detach File
Event Timeline
Log In to Comment