summary refs log tree commit diff
path: root/synapse/handlers
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/handlers')
-rw-r--r--synapse/handlers/appservice.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/synapse/handlers/appservice.py b/synapse/handlers/appservice.py
index 25447284eb..e68628bdfd 100644
--- a/synapse/handlers/appservice.py
+++ b/synapse/handlers/appservice.py
@@ -201,7 +201,9 @@ class ApplicationServicesHandler(object):
 
             # Merge the 'instances' lists of multiple results, but just take
             # the other fields from the first as they ought to be identical
+            # deep-clone the result so as not to corrupt the cached one
             combined = dict(infos[0])
+            combined["instances"] = list(combined["instances"])
 
             for info in infos[1:]:
                 combined["instances"].extend(info["instances"])