Remove unused code
authorSantiago Soto <santiago@soto.uy>
Wed, 3 Jul 2024 18:56:27 +0000 (15:56 -0300)
committerSantiago Soto <santiago@soto.uy>
Wed, 3 Jul 2024 18:56:27 +0000 (15:56 -0300)
music_assistant/server/providers/snapcast/__init__.py

index 92cdc6ec22615852b0939025d40f06dca01263d8..8d33af7db112ca8d015fae5eb0bd2c67df726648 100644 (file)
@@ -68,11 +68,6 @@ CONF_SERVER_DRYOUT_MS = "snapcast_stream_dryout_ms"
 # airplay has fixed sample rate/bit depth so make this config entry static and hidden
 CONF_ENTRY_SAMPLE_RATES_SNAPCAST = create_sample_rates_config_entry(48000, 16, 48000, 16, True)
 
-SNAP_STREAM_STATUS_MAP = {
-    "idle": PlayerState.IDLE,
-    "playing": PlayerState.PLAYING,
-    "unknown": PlayerState.IDLE,
-}
 DEFAULT_SNAPSERVER_PORT = 1705
 
 SNAPWEB_DIR: Final[pathlib.Path] = pathlib.Path(__file__).parent.resolve().joinpath("snapweb")
@@ -605,11 +600,6 @@ class SnapCastProvider(PlayerProvider):
         msg = "Unable to create stream - No free port found?"
         raise RuntimeError(msg)
 
-    def _get_player_state(self, player_id: str) -> PlayerState:
-        """Return the state of the player."""
-        snap_group = self._get_snapgroup(player_id)
-        return SNAP_STREAM_STATUS_MAP.get(snap_group.stream_status)
-
     def _set_childs_state(self, player_id: str, state: PlayerState) -> None:
         """Set the state of the child`s of the player."""
         for child_player_id in self._group_childs(player_id):