Skip to content

Commit

Permalink
fix import
Browse files Browse the repository at this point in the history
  • Loading branch information
adriangb committed Jun 15, 2023
1 parent 9f3ceaa commit 14bfdbf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/usage/types/custom.md
Expand Up @@ -226,7 +226,7 @@ print(Model2.model_json_schema())
You can also use `TypeAliasType` to create recursive types:

```py
from typing import Any, Dict, List
from typing import Any, Dict, List, Union

from pydantic_core import PydanticCustomError
from typing_extensions import Annotated, TypeAliasType
Expand Down Expand Up @@ -258,7 +258,7 @@ def json_custom_error_validator(
Json = TypeAliasType(
'Json',
Annotated[
Dict[str, 'Json'] | List['Json'] | str | int | float | bool | None,
Union[Dict[str, 'Json'], List['Json'], str, int, float, bool, None],
WrapValidator(json_custom_error_validator),
],
)
Expand Down

0 comments on commit 14bfdbf

Please sign in to comment.