mirror of
https://github.com/onyx-and-iris/voicemeeter-api-python.git
synced 2024-11-15 16:40:46 +00:00
check vban direction
check that index is numeric patch bump
This commit is contained in:
parent
08525b086c
commit
e9d1e7ffa2
@ -1,6 +1,6 @@
|
|||||||
[tool.poetry]
|
[tool.poetry]
|
||||||
name = "voicemeeter-api"
|
name = "voicemeeter-api"
|
||||||
version = "2.4.6"
|
version = "2.4.7"
|
||||||
description = "A Python wrapper for the Voiceemeter API"
|
description = "A Python wrapper for the Voiceemeter API"
|
||||||
authors = ["onyx-and-iris <code@onyxandiris.online>"]
|
authors = ["onyx-and-iris <code@onyxandiris.online>"]
|
||||||
license = "MIT"
|
license = "MIT"
|
||||||
|
@ -301,10 +301,16 @@ class Remote(CBindings):
|
|||||||
|
|
||||||
def target(key):
|
def target(key):
|
||||||
match key.split("-"):
|
match key.split("-"):
|
||||||
case ["strip" | "bus" | "button" as kls, index]:
|
case ["strip" | "bus" | "button" as kls, index] if index.isnumeric():
|
||||||
target = getattr(self, kls)
|
target = getattr(self, kls)
|
||||||
case ["vban", direction, index]:
|
case [
|
||||||
target = getattr(self.vban, f"{direction.rstrip('stream')}stream")
|
"vban",
|
||||||
|
"in" | "instream" | "out" | "outstream" as direction,
|
||||||
|
index,
|
||||||
|
] if index.isnumeric():
|
||||||
|
target = getattr(
|
||||||
|
self.vban, f"{direction.removesuffix('stream')}stream"
|
||||||
|
)
|
||||||
case _:
|
case _:
|
||||||
ERR_MSG = f"invalid config key '{key}'"
|
ERR_MSG = f"invalid config key '{key}'"
|
||||||
self.logger.error(ERR_MSG)
|
self.logger.error(ERR_MSG)
|
||||||
|
Loading…
Reference in New Issue
Block a user