|
@@ -539,9 +539,11 @@ class DeviceWorkerStore(RoomMemberWorkerStore, EndToEndKeyWorkerStore):
|
|
|
"device_id": device_id,
|
|
|
"prev_id": [prev_id] if prev_id else [],
|
|
|
"stream_id": stream_id,
|
|
|
- "org.matrix.opentracing_context": opentracing_context,
|
|
|
}
|
|
|
|
|
|
+ if opentracing_context != "{}":
|
|
|
+ result["org.matrix.opentracing_context"] = opentracing_context
|
|
|
+
|
|
|
prev_id = stream_id
|
|
|
|
|
|
if device is not None:
|
|
@@ -549,7 +551,11 @@ class DeviceWorkerStore(RoomMemberWorkerStore, EndToEndKeyWorkerStore):
|
|
|
if keys:
|
|
|
result["keys"] = keys
|
|
|
|
|
|
- device_display_name = device.display_name
|
|
|
+ device_display_name = None
|
|
|
+ if (
|
|
|
+ self.hs.config.federation.allow_device_name_lookup_over_federation
|
|
|
+ ):
|
|
|
+ device_display_name = device.display_name
|
|
|
if device_display_name:
|
|
|
result["device_display_name"] = device_display_name
|
|
|
else:
|