fix: custom module mediaplayer doesn't respect argument (#3198)
fix custom module mediaplayer which doesn't consider --exclude argument on player appear
This commit is contained in:
parent
50476edc98
commit
231d6972d7
|
@ -136,6 +136,10 @@ class PlayerManager:
|
||||||
|
|
||||||
def on_player_appeared(self, _, player):
|
def on_player_appeared(self, _, player):
|
||||||
logger.info(f"Player has appeared: {player.name}")
|
logger.info(f"Player has appeared: {player.name}")
|
||||||
|
if player.name in self.excluded_player:
|
||||||
|
logger.debug(
|
||||||
|
"New player appeared, but it's in exclude player list, skipping")
|
||||||
|
return
|
||||||
if player is not None and (self.selected_player is None or player.name == self.selected_player):
|
if player is not None and (self.selected_player is None or player.name == self.selected_player):
|
||||||
self.init_player(player)
|
self.init_player(player)
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in New Issue