We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Properly indented docstrings result in incorrectly rendered Markdown in openapi docs
**Describe the bug**

A properly formatted docstring is indented to match the indentation of the function or method. The markdown rendering that is passed into the API docs seems to be interpreting these indentations in such a way that the markdown is not properly formatted unless the docstring is out-dented to an unconventional flush left.

**To Reproduce**

I have the following function definition with docstring:

```
async def content_classifier_model_details(model_name:str) -> ModelClassDetailsResponse:
    """Retrieve the variants and versions of a group of content classifier models for a
    given named classification.

    Models can be specified at the `classify` endpoint as follows:

    - **Class name only** (`model_name`). E.g. `climate_action`. Will utilize the
    default model as indicated by the default flag in the model details. _This format
    is provided primarily for development and exploratory purposes._ In production
    code, it is recommended that the variant be specified.
    - **Class with variant** (`name-variant`). E.g. `climate_action-nx`. Will utilize
      the current version of the specified variant as indicated by the `current` field
      in the model details.
    - **Full versioned identifier** (`name-variant-version`). E.g. `climate_action-nx-1` is
      useful for pinning your application to a specific historical version.
    """
```
The result is shown in the screenshot titled incorrect-markdown-render.png. The expected rendering is shown in correct-markdown-render.png which can be achieved by the following unconventional docstring format:

```
async def content_classifier_model_details(model_name:str) -> ModelClassDetailsResponse:
    """Retrieve the variants and versions of a group of content classifier models for a
given named classification.

Models can be specified at the `classify` endpoint as follows:

- **Class name only** (`model_name`). E.g. `climate_action`. Will utilize the
default model as indicated by the default flag in the model details. _This format
is provided primarily for development and exploratory purposes._ In production
code, it is recommended that the variant be specified.
- **Class with variant** (`name-variant`). E.g. `climate_action-nx`. Will utilize
  the current version of the specified variant as indicated by the `current` field
  in the model details.
- **Full versioned identifier** (`name-variant-version`). E.g. `climate_action-nx-1` is
  useful for pinning your application to a specific historical version.
"""
```

## incorrect-markdown-render

<img width="579" alt="incorrect-markdown-render" src="https://user-images.githubusercontent.com/307713/200467063-af74141c-f289-49f0-afe6-1aa28e9bea73.png">

## correct-markdown-render

(achieved via unconventional docstring out-denting)

<img width="571" alt="correct-markdown-render" src="https://user-images.githubusercontent.com/307713/200467064-349dfbda-0a21-4d99-8929-ab3a9f51323f.png">



--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `starlite/openapi/path_item.py`
Content:
```
1 from typing import TYPE_CHECKING, Dict, List, Optional, Tuple, cast
2 
3 from pydantic_openapi_schema.v3_1_0.operation import Operation
4 from pydantic_openapi_schema.v3_1_0.path_item import PathItem
5 
6 from starlite.openapi.parameters import create_parameter_for_handler
7 from starlite.openapi.request_body import create_request_body
8 from starlite.openapi.responses import create_responses
9 from starlite.utils import get_name
10 
11 if TYPE_CHECKING:
12     from pydantic import BaseModel
13     from pydantic_openapi_schema.v3_1_0 import SecurityRequirement
14 
15     from starlite.handlers import HTTPRouteHandler
16     from starlite.plugins.base import PluginProtocol
17     from starlite.routes import HTTPRoute
18     from starlite.types import AnyCallable
19 
20 
21 def get_description_for_handler(route_handler: "HTTPRouteHandler", use_handler_docstrings: bool) -> Optional[str]:
22     """Produces the operation description for a route handler, either by using the description value if provided, or the docstring - if config is enabled.
23 
24     Args:
25         route_handler: A route handler instance.
26         use_handler_docstrings: If `True` and `route_handler.description` is `None` returns docstring of wrapped
27             handler function.
28 
29     Returns:
30         An optional description string
31     """
32     handler_description = route_handler.description
33     if handler_description is None and use_handler_docstrings:
34         return route_handler.fn.__doc__
35     return handler_description
36 
37 
38 def extract_layered_values(
39     route_handler: "HTTPRouteHandler",
40 ) -> Tuple[Optional[List[str]], Optional[List[Dict[str, List[str]]]]]:
41     """Extracts the tags and security values from the route handler layers.
42 
43     Args:
44         route_handler: A Route Handler instance.
45 
46     Returns:
47         A tuple of optional lists.
48     """
49     tags: List[str] = []
50     security: List["SecurityRequirement"] = []
51     for layer in route_handler.ownership_layers:
52         if layer.tags:
53             tags.extend(layer.tags)
54         if layer.security:
55             security.extend(layer.security)
56     return list(set(tags)) if tags else None, security or None
57 
58 
59 def create_path_item(
60     route: "HTTPRoute", create_examples: bool, plugins: List["PluginProtocol"], use_handler_docstrings: bool
61 ) -> PathItem:
62     """Create a PathItem model for the given route parsing all http_methods
63     into Operation Models."""
64     path_item = PathItem()
65     for http_method, handler_tuple in route.route_handler_map.items():
66         route_handler, _ = handler_tuple
67         if route_handler.include_in_schema:
68             handler_fields = cast("BaseModel", route_handler.signature_model).__fields__
69             parameters = (
70                 create_parameter_for_handler(
71                     route_handler=route_handler,
72                     handler_fields=handler_fields,
73                     path_parameters=route.path_parameters,
74                     generate_examples=create_examples,
75                 )
76                 or None
77             )
78             raises_validation_error = bool("data" in handler_fields or path_item.parameters or parameters)
79             handler_name = get_name(cast("AnyCallable", route_handler.fn)).replace("_", " ").title()
80             request_body = None
81             if "data" in handler_fields:
82                 request_body = create_request_body(
83                     field=handler_fields["data"], generate_examples=create_examples, plugins=plugins
84                 )
85 
86             tags, security = extract_layered_values(route_handler)
87             operation = Operation(
88                 operationId=route_handler.operation_id or handler_name,
89                 tags=tags,
90                 summary=route_handler.summary,
91                 description=get_description_for_handler(route_handler, use_handler_docstrings),
92                 deprecated=route_handler.deprecated,
93                 responses=create_responses(
94                     route_handler=route_handler,
95                     raises_validation_error=raises_validation_error,
96                     generate_examples=create_examples,
97                     plugins=plugins,
98                 ),
99                 requestBody=request_body,
100                 parameters=parameters,  # type: ignore[arg-type]
101                 security=security,
102             )
103             setattr(path_item, http_method.lower(), operation)
104     return path_item
105
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/starlite/openapi/path_item.py b/starlite/openapi/path_item.py
--- a/starlite/openapi/path_item.py
+++ b/starlite/openapi/path_item.py
@@ -1,3 +1,4 @@
+from inspect import cleandoc
 from typing import TYPE_CHECKING, Dict, List, Optional, Tuple, cast
 
 from pydantic_openapi_schema.v3_1_0.operation import Operation
@@ -31,7 +32,7 @@
     """
     handler_description = route_handler.description
     if handler_description is None and use_handler_docstrings:
-        return route_handler.fn.__doc__
+        return cleandoc(route_handler.fn.__doc__) if route_handler.fn.__doc__ else None
     return handler_description

{"golden_diff": "diff --git a/starlite/openapi/path_item.py b/starlite/openapi/path_item.py\n--- a/starlite/openapi/path_item.py\n+++ b/starlite/openapi/path_item.py\n@@ -1,3 +1,4 @@\n+from inspect import cleandoc\n from typing import TYPE_CHECKING, Dict, List, Optional, Tuple, cast\n \n from pydantic_openapi_schema.v3_1_0.operation import Operation\n@@ -31,7 +32,7 @@\n     \"\"\"\n     handler_description = route_handler.description\n     if handler_description is None and use_handler_docstrings:\n-        return route_handler.fn.__doc__\n+        return cleandoc(route_handler.fn.__doc__) if route_handler.fn.__doc__ else None\n     return handler_description\n", "issue": "Properly indented docstrings result in incorrectly rendered Markdown in openapi docs\n**Describe the bug**\r\n\r\nA properly formatted docstring is indented to match the indentation of the function or method. The markdown rendering that is passed into the API docs seems to be interpreting these indentations in such a way that the markdown is not properly formatted unless the docstring is out-dented to an unconventional flush left.\r\n\r\n**To Reproduce**\r\n\r\nI have the following function definition with docstring:\r\n\r\n```\r\nasync def content_classifier_model_details(model_name:str) -> ModelClassDetailsResponse:\r\n    \"\"\"Retrieve the variants and versions of a group of content classifier models for a\r\n    given named classification.\r\n\r\n    Models can be specified at the `classify` endpoint as follows:\r\n\r\n    - **Class name only** (`model_name`). E.g. `climate_action`. Will utilize the\r\n    default model as indicated by the default flag in the model details. _This format\r\n    is provided primarily for development and exploratory purposes._ In production\r\n    code, it is recommended that the variant be specified.\r\n    - **Class with variant** (`name-variant`). E.g. `climate_action-nx`. Will utilize\r\n      the current version of the specified variant as indicated by the `current` field\r\n      in the model details.\r\n    - **Full versioned identifier** (`name-variant-version`). E.g. `climate_action-nx-1` is\r\n      useful for pinning your application to a specific historical version.\r\n    \"\"\"\r\n```\r\nThe result is shown in the screenshot titled incorrect-markdown-render.png. The expected rendering is shown in correct-markdown-render.png which can be achieved by the following unconventional docstring format:\r\n\r\n```\r\nasync def content_classifier_model_details(model_name:str) -> ModelClassDetailsResponse:\r\n    \"\"\"Retrieve the variants and versions of a group of content classifier models for a\r\ngiven named classification.\r\n\r\nModels can be specified at the `classify` endpoint as follows:\r\n\r\n- **Class name only** (`model_name`). E.g. `climate_action`. Will utilize the\r\ndefault model as indicated by the default flag in the model details. _This format\r\nis provided primarily for development and exploratory purposes._ In production\r\ncode, it is recommended that the variant be specified.\r\n- **Class with variant** (`name-variant`). E.g. `climate_action-nx`. Will utilize\r\n  the current version of the specified variant as indicated by the `current` field\r\n  in the model details.\r\n- **Full versioned identifier** (`name-variant-version`). E.g. `climate_action-nx-1` is\r\n  useful for pinning your application to a specific historical version.\r\n\"\"\"\r\n```\r\n\r\n## incorrect-markdown-render\r\n\r\n<img width=\"579\" alt=\"incorrect-markdown-render\" src=\"https://user-images.githubusercontent.com/307713/200467063-af74141c-f289-49f0-afe6-1aa28e9bea73.png\">\r\n\r\n## correct-markdown-render\r\n\r\n(achieved via unconventional docstring out-denting)\r\n\r\n<img width=\"571\" alt=\"correct-markdown-render\" src=\"https://user-images.githubusercontent.com/307713/200467064-349dfbda-0a21-4d99-8929-ab3a9f51323f.png\">\r\n\r\n\n", "before_files": [{"content": "from typing import TYPE_CHECKING, Dict, List, Optional, Tuple, cast\n\nfrom pydantic_openapi_schema.v3_1_0.operation import Operation\nfrom pydantic_openapi_schema.v3_1_0.path_item import PathItem\n\nfrom starlite.openapi.parameters import create_parameter_for_handler\nfrom starlite.openapi.request_body import create_request_body\nfrom starlite.openapi.responses import create_responses\nfrom starlite.utils import get_name\n\nif TYPE_CHECKING:\n    from pydantic import BaseModel\n    from pydantic_openapi_schema.v3_1_0 import SecurityRequirement\n\n    from starlite.handlers import HTTPRouteHandler\n    from starlite.plugins.base import PluginProtocol\n    from starlite.routes import HTTPRoute\n    from starlite.types import AnyCallable\n\n\ndef get_description_for_handler(route_handler: \"HTTPRouteHandler\", use_handler_docstrings: bool) -> Optional[str]:\n    \"\"\"Produces the operation description for a route handler, either by using the description value if provided, or the docstring - if config is enabled.\n\n    Args:\n        route_handler: A route handler instance.\n        use_handler_docstrings: If `True` and `route_handler.description` is `None` returns docstring of wrapped\n            handler function.\n\n    Returns:\n        An optional description string\n    \"\"\"\n    handler_description = route_handler.description\n    if handler_description is None and use_handler_docstrings:\n        return route_handler.fn.__doc__\n    return handler_description\n\n\ndef extract_layered_values(\n    route_handler: \"HTTPRouteHandler\",\n) -> Tuple[Optional[List[str]], Optional[List[Dict[str, List[str]]]]]:\n    \"\"\"Extracts the tags and security values from the route handler layers.\n\n    Args:\n        route_handler: A Route Handler instance.\n\n    Returns:\n        A tuple of optional lists.\n    \"\"\"\n    tags: List[str] = []\n    security: List[\"SecurityRequirement\"] = []\n    for layer in route_handler.ownership_layers:\n        if layer.tags:\n            tags.extend(layer.tags)\n        if layer.security:\n            security.extend(layer.security)\n    return list(set(tags)) if tags else None, security or None\n\n\ndef create_path_item(\n    route: \"HTTPRoute\", create_examples: bool, plugins: List[\"PluginProtocol\"], use_handler_docstrings: bool\n) -> PathItem:\n    \"\"\"Create a PathItem model for the given route parsing all http_methods\n    into Operation Models.\"\"\"\n    path_item = PathItem()\n    for http_method, handler_tuple in route.route_handler_map.items():\n        route_handler, _ = handler_tuple\n        if route_handler.include_in_schema:\n            handler_fields = cast(\"BaseModel\", route_handler.signature_model).__fields__\n            parameters = (\n                create_parameter_for_handler(\n                    route_handler=route_handler,\n                    handler_fields=handler_fields,\n                    path_parameters=route.path_parameters,\n                    generate_examples=create_examples,\n                )\n                or None\n            )\n            raises_validation_error = bool(\"data\" in handler_fields or path_item.parameters or parameters)\n            handler_name = get_name(cast(\"AnyCallable\", route_handler.fn)).replace(\"_\", \" \").title()\n            request_body = None\n            if \"data\" in handler_fields:\n                request_body = create_request_body(\n                    field=handler_fields[\"data\"], generate_examples=create_examples, plugins=plugins\n                )\n\n            tags, security = extract_layered_values(route_handler)\n            operation = Operation(\n                operationId=route_handler.operation_id or handler_name,\n                tags=tags,\n                summary=route_handler.summary,\n                description=get_description_for_handler(route_handler, use_handler_docstrings),\n                deprecated=route_handler.deprecated,\n                responses=create_responses(\n                    route_handler=route_handler,\n                    raises_validation_error=raises_validation_error,\n                    generate_examples=create_examples,\n                    plugins=plugins,\n                ),\n                requestBody=request_body,\n                parameters=parameters,  # type: ignore[arg-type]\n                security=security,\n            )\n            setattr(path_item, http_method.lower(), operation)\n    return path_item\n", "path": "starlite/openapi/path_item.py"}], "after_files": [{"content": "from inspect import cleandoc\nfrom typing import TYPE_CHECKING, Dict, List, Optional, Tuple, cast\n\nfrom pydantic_openapi_schema.v3_1_0.operation import Operation\nfrom pydantic_openapi_schema.v3_1_0.path_item import PathItem\n\nfrom starlite.openapi.parameters import create_parameter_for_handler\nfrom starlite.openapi.request_body import create_request_body\nfrom starlite.openapi.responses import create_responses\nfrom starlite.utils import get_name\n\nif TYPE_CHECKING:\n    from pydantic import BaseModel\n    from pydantic_openapi_schema.v3_1_0 import SecurityRequirement\n\n    from starlite.handlers import HTTPRouteHandler\n    from starlite.plugins.base import PluginProtocol\n    from starlite.routes import HTTPRoute\n    from starlite.types import AnyCallable\n\n\ndef get_description_for_handler(route_handler: \"HTTPRouteHandler\", use_handler_docstrings: bool) -> Optional[str]:\n    \"\"\"Produces the operation description for a route handler, either by using the description value if provided, or the docstring - if config is enabled.\n\n    Args:\n        route_handler: A route handler instance.\n        use_handler_docstrings: If `True` and `route_handler.description` is `None` returns docstring of wrapped\n            handler function.\n\n    Returns:\n        An optional description string\n    \"\"\"\n    handler_description = route_handler.description\n    if handler_description is None and use_handler_docstrings:\n        return cleandoc(route_handler.fn.__doc__) if route_handler.fn.__doc__ else None\n    return handler_description\n\n\ndef extract_layered_values(\n    route_handler: \"HTTPRouteHandler\",\n) -> Tuple[Optional[List[str]], Optional[List[Dict[str, List[str]]]]]:\n    \"\"\"Extracts the tags and security values from the route handler layers.\n\n    Args:\n        route_handler: A Route Handler instance.\n\n    Returns:\n        A tuple of optional lists.\n    \"\"\"\n    tags: List[str] = []\n    security: List[\"SecurityRequirement\"] = []\n    for layer in route_handler.ownership_layers:\n        if layer.tags:\n            tags.extend(layer.tags)\n        if layer.security:\n            security.extend(layer.security)\n    return list(set(tags)) if tags else None, security or None\n\n\ndef create_path_item(\n    route: \"HTTPRoute\", create_examples: bool, plugins: List[\"PluginProtocol\"], use_handler_docstrings: bool\n) -> PathItem:\n    \"\"\"Create a PathItem model for the given route parsing all http_methods\n    into Operation Models.\"\"\"\n    path_item = PathItem()\n    for http_method, handler_tuple in route.route_handler_map.items():\n        route_handler, _ = handler_tuple\n        if route_handler.include_in_schema:\n            handler_fields = cast(\"BaseModel\", route_handler.signature_model).__fields__\n            parameters = (\n                create_parameter_for_handler(\n                    route_handler=route_handler,\n                    handler_fields=handler_fields,\n                    path_parameters=route.path_parameters,\n                    generate_examples=create_examples,\n                )\n                or None\n            )\n            raises_validation_error = bool(\"data\" in handler_fields or path_item.parameters or parameters)\n            handler_name = get_name(cast(\"AnyCallable\", route_handler.fn)).replace(\"_\", \" \").title()\n            request_body = None\n            if \"data\" in handler_fields:\n                request_body = create_request_body(\n                    field=handler_fields[\"data\"], generate_examples=create_examples, plugins=plugins\n                )\n\n            tags, security = extract_layered_values(route_handler)\n            operation = Operation(\n                operationId=route_handler.operation_id or handler_name,\n                tags=tags,\n                summary=route_handler.summary,\n                description=get_description_for_handler(route_handler, use_handler_docstrings),\n                deprecated=route_handler.deprecated,\n                responses=create_responses(\n                    route_handler=route_handler,\n                    raises_validation_error=raises_validation_error,\n                    generate_examples=create_examples,\n                    plugins=plugins,\n                ),\n                requestBody=request_body,\n                parameters=parameters,  # type: ignore[arg-type]\n                security=security,\n            )\n            setattr(path_item, http_method.lower(), operation)\n    return path_item\n", "path": "starlite/openapi/path_item.py"}]}