From 3887dce508e0f85073a227337861b569bfd3a04b Mon Sep 17 00:00:00 2001 From: Manuel Cortez Date: Fri, 21 Dec 2018 16:21:19 -0600 Subject: [PATCH] Handles case when an audio object has been deleted by the user --- src/sessionmanager/renderers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sessionmanager/renderers.py b/src/sessionmanager/renderers.py index f91055c..fe955b7 100644 --- a/src/sessionmanager/renderers.py +++ b/src/sessionmanager/renderers.py @@ -87,7 +87,7 @@ def render_newsfeed_item(status, session): if message == "": message = "no description available" # Handle audio rendering. - elif status["type"] == "audio": + elif status["type"] == "audio" and "audio" in status: # removes deleted audios. status["audio"] = clean_audio(status["audio"]) if status["audio"]["count"] == 1: