diff --git a/gso/utils/types/multi_exit_discriminator.py b/gso/utils/types/multi_exit_discriminator.py
index d894fd448f07c4516b47f3ffdb8da2a635586a6b..b0dd02c0978f158f57b2ecd3e0e11263263835a8 100644
--- a/gso/utils/types/multi_exit_discriminator.py
+++ b/gso/utils/types/multi_exit_discriminator.py
@@ -1,17 +1,11 @@
"""Type definition for a BGP Multi Exit Discriminator."""
import contextlib
-from typing import Annotated, Any
+from typing import Annotated
from pydantic import AfterValidator, BeforeValidator
-def _ensure_str(value: Any) -> Any:
- if not isinstance(value, str):
- return str(value)
- return value
-
-
def _multi_exit_discriminator_valid(value: str) -> str:
with contextlib.suppress(ValueError):
int_value = int(value)
@@ -25,4 +19,4 @@ def _multi_exit_discriminator_valid(value: str) -> str:
raise ValueError(msg)
-MultiExitDiscriminator = Annotated[str, BeforeValidator(_ensure_str), AfterValidator(_multi_exit_discriminator_valid)]
+MultiExitDiscriminator = Annotated[str, BeforeValidator(str), AfterValidator(_multi_exit_discriminator_valid)]