Skip to content

Extensions related question #202

@ubogdan

Description

@ubogdan

Hi,
Is there any special reason why the keyname of extension is lowered ?

// Add adds a value to these extensions
func (e Extensions) Add(key string, value interface{}) {
	realKey := strings.ToLower(key)
	e[realKey] = value
}

I checked OAS2 Specification Extensions and there is no reference about lowercase.

Thanks,
Bogdan

Activity

fredbi

fredbi commented on Mar 13, 2025

@fredbi
Member

@ubogdan I believe that at the time, we wanted some kind of canonicalization for extensions (similar to headers).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @ubogdan@fredbi

        Issue actions

          Extensions related question · Issue #202 · go-openapi/spec