mirror of
https://github.com/onyx-and-iris/voicemeeter-api-python.git
synced 2024-11-15 16:40:46 +00:00
raise VMError on invalid kind
This commit is contained in:
parent
6c4259d6de
commit
064cfeb23d
@ -1,6 +1,8 @@
|
||||
from dataclasses import dataclass
|
||||
from enum import Enum, unique
|
||||
|
||||
from .error import VMError
|
||||
|
||||
|
||||
@unique
|
||||
class KindId(Enum):
|
||||
@ -105,7 +107,7 @@ def request_kind_map(kind_id):
|
||||
try:
|
||||
KIND_obj = kind_factory(kind_id)
|
||||
except ValueError as e:
|
||||
print(e)
|
||||
raise VMError(str(e)) from e
|
||||
return KIND_obj
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user