Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(uuid): UUID regexes to support all-or-none '-' separator #113

Merged
merged 1 commit into from
Dec 28, 2023

Commits on Dec 28, 2023

  1. fix(uuid): UUID regexes to support all-or-none '-' separator

    This PR changes the UUID validation to support either
    UUIDs with the expected number of separators or no separator at all.
    
    Under the hood, UUID validation no longer relies on regular expressions
    (exported regexp patterns are marked as deprecated) but on
    github.com/google/uuid. This brings a significant performance
    improvement on validation (~ 15-20 times faster).
    
    Notice that some non-standard UUID schemes as well as UUID v6 and v7
    now pass "IsUUID".
    
    * contributes go-swagger/go-swagger#2878
    
    Signed-off-by: Frederic BIDON <fredbi@yahoo.com>
    fredbi committed Dec 28, 2023
    Configuration menu
    Copy the full SHA
    b556c74 View commit details
    Browse the repository at this point in the history