Skip to content
This repository has been archived by the owner on May 26, 2022. It is now read-only.

Commit

Permalink
Update __init__.py
Browse files Browse the repository at this point in the history
  • Loading branch information
maykar authored Mar 28, 2020
1 parent 8bf4b1e commit d6c4e1d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions custom_components/plex_assistant/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,9 @@ def handle_input(call):
PA.lib = get_libraries(PA.plex)

try:
device = fuzzy(command["device"] or default_cast,
PA.device_names + PA.client_names)
alias = fuzzy(command["device"], PA.alias_names)
devices = PA.device_names + PA.client_names
device = fuzzy(command["device"] or default_cast, devices)
alias = fuzzy(command["device"] or default_cast, PA.alias_names)
name = aliases[alias[0]] if alias[1] > device[1] else device[0]
cast = PA.devices[name] if name in PA.device_names else name
except Exception:
Expand Down

0 comments on commit d6c4e1d

Please sign in to comment.