From 58e207cd77b3b68b1908078418c9c9e9c3830ea5 Mon Sep 17 00:00:00 2001
From: Erik Johnston <erik@matrix.org>
Date: Fri, 18 Mar 2016 14:31:44 +0000
Subject: [PATCH] Don't assume existence of event_id in __str__

---
 synapse/events/__init__.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/synapse/events/__init__.py b/synapse/events/__init__.py
index bbfa5a726..abed6b5e6 100644
--- a/synapse/events/__init__.py
+++ b/synapse/events/__init__.py
@@ -168,5 +168,7 @@ class FrozenEvent(EventBase):
 
     def __repr__(self):
         return "<FrozenEvent event_id='%s', type='%s', state_key='%s'>" % (
-            self.event_id, self.type, self.get("state_key", None),
+            self.get("event_id", None),
+            self.get("type", None),
+            self.get("state_key", None),
         )