refactor(vlc_service): remove unused parameters ip_address and user_agent from play_sound method
This commit is contained in:
@@ -20,7 +20,7 @@ class VLCService:
|
|||||||
self.processes: Dict[str, subprocess.Popen] = {}
|
self.processes: Dict[str, subprocess.Popen] = {}
|
||||||
self.lock = threading.Lock()
|
self.lock = threading.Lock()
|
||||||
|
|
||||||
def play_sound(self, sound_id: int, user_id: int | None = None, ip_address: str | None = None, user_agent: str | None = None) -> bool:
|
def play_sound(self, sound_id: int, user_id: int | None = None) -> bool:
|
||||||
"""Play a sound by ID using VLC subprocess."""
|
"""Play a sound by ID using VLC subprocess."""
|
||||||
try:
|
try:
|
||||||
# Get sound from database
|
# Get sound from database
|
||||||
@@ -86,8 +86,6 @@ class VLCService:
|
|||||||
SoundPlayed.create_play_record(
|
SoundPlayed.create_play_record(
|
||||||
user_id=user_id,
|
user_id=user_id,
|
||||||
sound_id=sound_id,
|
sound_id=sound_id,
|
||||||
ip_address=ip_address,
|
|
||||||
user_agent=user_agent,
|
|
||||||
commit=True,
|
commit=True,
|
||||||
)
|
)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
|||||||
Reference in New Issue
Block a user