From 49bbdb3c21e54dd9d66b2ceab449f7f2e4bafcb8 Mon Sep 17 00:00:00 2001
From: uvjustin <46082645+uvjustin@users.noreply.github.com>
Date: Fri, 3 Jul 2020 01:51:13 +0800
Subject: [PATCH] =?UTF-8?q?Use=20entry.data.get()=20in=20forked=5Fdaapd=20?=
 =?UTF-8?q?config=5Fflow=20as=20some=20entries=20miss=E2=80=A6=20(#37359)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 homeassistant/components/forked_daapd/config_flow.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/homeassistant/components/forked_daapd/config_flow.py b/homeassistant/components/forked_daapd/config_flow.py
index d27c40af316..45ea8861d4a 100644
--- a/homeassistant/components/forked_daapd/config_flow.py
+++ b/homeassistant/components/forked_daapd/config_flow.py
@@ -133,7 +133,7 @@ class ForkedDaapdFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
         if user_input is not None:
             # check for any entries with same host, abort if found
             for entry in self._async_current_entries():
-                if entry.data[CONF_HOST] == user_input[CONF_HOST]:
+                if entry.data.get(CONF_HOST) == user_input[CONF_HOST]:
                     return self.async_abort(reason="already_configured")
             validate_result = await self.validate_input(user_input)
             if validate_result[0] == "ok":  # success
-- 
GitLab