yuka1984 / azure-functions-extensions-swashbuckle

MIT License
33 stars 29 forks source link

Fix documents option configuration #10

Closed rafaelfbs closed 5 years ago

rafaelfbs commented 5 years ago

When adding a document for "v1", the following exception throws in console:

System.Private.CoreLib: Exception while executing function: Swagger. System.Private.CoreLib: An item with the same key has already been added. Key: v1.

host.json:

{
    "version": "2.0",
    "extensions": {
        "Swashbuckle": {
            "Title": "Swagger Title",
            "XmlPath": "FunctionDocs.xml",
            "Documents": [
                {
                    "Name": "v1",
                    "Title": "Swagger v1 Title",
                    "Version": "v1",
                    "Description": "Swagger v1 Description"
                }
            ]
        }
    }
}