mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-06 15:21:13 +02:00
Fix enum use in schemas
This commit is contained in:
1 parent
bd9af3fe90
commit
31ae70894e
5 files changed
+33
-33
No files matched your search
@@ -22,7 +22,7 @@ from uuid import UUID
|
||||
from ..common import NodeStatus
|
||||
|
||||
|
||||
class HostInterfaceType(Enum):
|
||||
class HostInterfaceType(str, Enum):
|
||||
|
||||
ethernet = "ethernet"
|
||||
tap = "tap"
|
||||
@@ -38,7 +38,7 @@ class HostInterface(BaseModel):
|
||||
special: bool = Field(..., description="Whether the interface is non standard")
|
||||
|
||||
|
||||
class EthernetType(Enum):
|
||||
class EthernetType(str, Enum):
|
||||
ethernet = "ethernet"
|
||||
|
||||
|
||||
@@ -53,7 +53,7 @@ class EthernetPort(BaseModel):
|
||||
interface: str
|
||||
|
||||
|
||||
class TAPType(Enum):
|
||||
class TAPType(str, Enum):
|
||||
tap = "tap"
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ class TAPPort(BaseModel):
|
||||
interface: str
|
||||
|
||||
|
||||
class UDPType(Enum):
|
||||
class UDPType(str, Enum):
|
||||
udp = "udp"
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user