mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-27 11:06:32 +00:00
fix v2
This commit is contained in:
parent
743a218219
commit
c5ee2ebc49
@ -85,6 +85,7 @@ class AlsaAudio(CoreSysAttributes):
|
|||||||
def default(self):
|
def default(self):
|
||||||
"""Generate ALSA default setting."""
|
"""Generate ALSA default setting."""
|
||||||
# Init defaults
|
# Init defaults
|
||||||
|
try:
|
||||||
if self._default is None:
|
if self._default is None:
|
||||||
database = self._audio_database()
|
database = self._audio_database()
|
||||||
alsa_input = database.get(self._machine, {}).get(ATTR_INPUT)
|
alsa_input = database.get(self._machine, {}).get(ATTR_INPUT)
|
||||||
@ -101,6 +102,8 @@ class AlsaAudio(CoreSysAttributes):
|
|||||||
if self._default.input is None and self.input_devices:
|
if self._default.input is None and self.input_devices:
|
||||||
self._default.input = next(iter(self.input_devices))
|
self._default.input = next(iter(self.input_devices))
|
||||||
_LOGGER.info("Detect input device %s", self._default.input)
|
_LOGGER.info("Detect input device %s", self._default.input)
|
||||||
|
except:
|
||||||
|
_LOGGER.exception("hmm2")
|
||||||
|
|
||||||
return self._default
|
return self._default
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user